Welcome to the SRP Forum! Please refer to the SRP Forum FAQ post if you have any questions regarding how the forum works.

Send_Event

Normally to get an event to fire I do this
Call Send_Event(CurCtrl, "CHANGED")
How do I get a Changed event to fire on your OLE EditTable?

Comments

  • Call Send_Event(CurCtrl, "OLE", "AfterUpdate", "1;2", "NewText", "")
  • A bit more of an explanation. and thank you for the help.
    I copied a bunch of data into an OLE EditTable using the OLE.LIST property.
    Normally when typing data (as opposed to using the property) I use the changed event to write the data to tables.
    When I use OLE.LIST obviously no changed events fires, my thought was after pasting the data, I'd go to each cell and fire a changed event. Then the existing code would handle writing all the data.
    How would I fire a changed event on each cell?
  • Actually it's the BeforeUpdate event I use not changed event.
  • The direct answer to your question is that you have to do a SendEvent for each cell, passing the cell position as a parameter. The trick to sending OLE events is that the actual event is "OLE" and the next parameter is the control's event itself. The parameters after that are the event's parameters.

    My personal preference is to avoid Send_Event if possible as it adds a lot of overhead. I would move the pertinent logic within your BeforeUpdate event into a GoSub and just call that GoSub as needed when setting the LIST property.
  • Ok, I understand.

    Thank you for the help.
Sign In or Register to comment.