GrapeCity Forums

The GrapeCity Message Boards
Welcome to GrapeCity Forums Sign in | Join | Help
in Search

Help working with Button

Last post 07-03-2009, 11:51 AM by scotts. 2 replies.
Sort Posts: Previous Next
  •  07-03-2009, 7:11 AM 79817

    Help working with Button

    Hi.

    I'm using Spread 7.0. My issue is:

    I have 4 col and 1 row grid. In cells 1 and 3 I have and edit type cell, in cells 2 and 4 i have buttons type cell.

    I need to do that: I need to activate cell 2 and 4 (buttons type) only when i click on it.  I mean to consultate a master table to locate the record needed in cells 1 and 3. I don't want to pass focus when navegate in the grid. 

    When i click tab from cells 1 a need the cursor to move to cell 3 only enter to cells 2 and 4 when i click on it.

    Thanks for help and sorry for my english.

     

     

     


     

  •  07-03-2009, 7:25 AM 79818 in reply to 79817

    Re: Help working with Button

    I'm using vb6 with Spread 7.0
  •  07-03-2009, 11:51 AM 79836 in reply to 79817

    Re: Help working with Button

    Hello,

    The Click event should fire before the LeaveCell event, so you could set a global flag in the Click event if it is column 2 or 4. Then, in the LeaveCell event check for the flag. If it is not set then you can look at the Row, Col, NewRow and NewCol parameters to see what the active cell was and what the user is trying to move the active cell to. If it is not where you want the active cell to go, you can set the Cancel parameter of the event to True and call the SetActiveCell method to move the active cell to where you want it.


    Scott S.
    Product Manager, Spread ASP.NET
    GrapeCity FarPoint
View as RSS news feed in XML
     FarPoint Forums Home