PxPlus User Forum

Twitter Twitter Twitter

Author Topic: Grid Control: Button click functionalities  (Read 1502 times)

Prajin P K

  • Silver Member
  • ***
  • Posts: 21
  • Beginner in PvxPlus
    • View Profile
Grid Control: Button click functionalities
« on: December 12, 2019, 04:42:27 AM »
Hi Team,
       We've added buttons on each row to perform delete, save, etc for each record on grid control. please help us provide solution to do those operations in class program(.PVC) while clicking on particular button.
Prajin P K
Software Engineer,
World Source Infotech,
Bangalore, India.

Mike King

  • Diamond Member
  • *****
  • Posts: 3818
  • Mike King
    • View Profile
    • BBSysco Consulting
Re: Grid Control: Button click functionalities
« Reply #1 on: December 12, 2019, 10:24:31 AM »
One method  would be to add a Cell Logic to the grid in for the column which contains the button -- something like _obj'GridButtonClick(id.row) -- which should invoke the method and pass it the row.

Another is to test the values in id.row and id.column in the Grid on change method and based on the Column invoke whatever logic you want.  Something like:

  Function ChangeGrid_1()
  if id.column = 1 return _Obj'GridButtonClick(id.row) ! Column 1 is the button
  ...
Mike King
President - BBSysco Consulting
eMail: mike.king@bbsysco.com

Prajin P K

  • Silver Member
  • ***
  • Posts: 21
  • Beginner in PvxPlus
    • View Profile
Re: Grid Control: Button click functionalities
« Reply #2 on: December 13, 2019, 12:30:52 AM »
Thank you mike
Prajin P K
Software Engineer,
World Source Infotech,
Bangalore, India.