pio Posted October 15, 2011 Share Posted October 15, 2011 Hi, I have a table with approx. 100 rows and 10 columns, and I need to get the index of user-clicked-row. Can I do it in DAQ? I am using DAQ 5.84 Developer version. Any help would be appreciated. Quote Link to comment Share on other sites More sharing options...
AzeoTech Posted October 17, 2011 Share Posted October 17, 2011 No, not with a table control. You could do it with a tree control to create a what is generally called a list box, but that only would have one column. Quote Link to comment Share on other sites More sharing options...
AzeoTech Posted October 17, 2011 Share Posted October 17, 2011 That said, you could try and render your own table out of variable value controls. Then you could do it. It would be a little more combursome to create and would work a little different than a standard table (probably with scroll buttons instead of a slider), but would achieve the same thing. In some ways, especially for a touch screen, it would probably work better than a table. Quote Link to comment Share on other sites More sharing options...
andrewjfox Posted November 21, 2011 Share Posted November 21, 2011 Hi, Just saw post while looking for something else, and thought I'd share my solution to same problem When the user clicks anywhere on the table you can get the coords relative to the table top left, then using the row height you can figure out which row they clicked. In the table component OnLButtonDown event Row = Floor((loc[0][1] / RowHeight)) - DisplayTitles Hope this helps Cheers Quote Link to comment Share on other sites More sharing options...
AzeoTech Posted November 22, 2011 Share Posted November 22, 2011 Thanks Andrew! Your method would work quite well. Quote Link to comment Share on other sites More sharing options...
moheb Posted March 30, 2015 Share Posted March 30, 2015 if I have table with 50 rows length . and table contents depend on access database . sometimes table contains more than 300 rows, so scroll bar appear with two arrows (moving up and down ). pressing arrow move the table one row can I create button act like  scroll bar arrow but by pressing it the table move 50 rows not one  Quote Link to comment Share on other sites More sharing options...
AzeoTech Posted March 31, 2015 Share Posted March 31, 2015 Sure. Â Give the table component a name. Â Then there is a member variable called "topRow" which you can read and write to. Â So, assuming your table is called "MyTable", to move forward 50 rows, you'd do: Â component.myTable.topRow += 50 Â to move the other way, do -= Quote Link to comment Share on other sites More sharing options...
kanber Posted January 11, 2020 Share Posted January 11, 2020 this function working on pages. I need to do on popup. How can I do? Quote Link to comment Share on other sites More sharing options...
AzeoTech Posted January 14, 2020 Share Posted January 14, 2020 It should work in the popup as well. Quote Link to comment Share on other sites More sharing options...
kanber Posted January 14, 2020 Share Posted January 14, 2020 OnMouseMove function I put script "global Row4 = loc[0][1]" Row4 is change on pages. but when I open popup it is not changing. Also when popup is open, outside the popup page it is working. but I need to X and Y on popup. Quote Link to comment Share on other sites More sharing options...
AzeoTech Posted January 14, 2020 Share Posted January 14, 2020 OnMouseMove does not function in popups. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.