Zhimin is right with his suggestion, but if you just want the selected
row number, there is a simpler method. Did you look at
WAbstractItemView::selectedIndexes() ?

http://www.webtoolkit.eu/wt/doc/reference/html/classWt_1_1WAbstractItemView.html#afde08bb75862592d81dc93f30ed7dcd6

Wim.

2011/8/15  <[email protected]>:
> Hi, my name is Mario Diethelm. I am a C/C++ programmer making my first steps
> in the field of Web applications.
>
> I have started to work with Wt a couple of months ago. I am building an 
> application
> that needs to load rows of data from a data base and present it on the 
> browser.
> I am using a WStandardItemModel to load the actual data and a WTableView
> to display it. The user then must select one of the records available to
> make some process based on the data selected.
>
> The question is: how do I identify the selected record? I do not have problems
> loading the data into the WStandardItemModel, or presenting it on the screen,
> using the WTableView widget. Even more, in a row basis, I can select the
> required record but I can not realize how to identify it and access the actual
> data in my program. I have been looking the Class Reference and source code
> examples but I can not find a way to recognize the "current selected record"
> neither how to manage it inside the application.
>
> I would appreciate if somebody could give me some advice. I am using Wt 3.1.7.
>
> Thanks and regards.
>
> Mario Diethelm.
>
>
>
> ------------------------------------------------------------------------------
> uberSVN's rich system and user administration capabilities and model
> configuration take the hassle out of deploying and managing Subversion and
> the tools developers use with it. Learn more about uberSVN and get a free
> download at:  http://p.sf.net/sfu/wandisco-dev2dev
> _______________________________________________
> witty-interest mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/witty-interest
>

------------------------------------------------------------------------------
uberSVN's rich system and user administration capabilities and model 
configuration take the hassle out of deploying and managing Subversion and 
the tools developers use with it. Learn more about uberSVN and get a free 
download at:  http://p.sf.net/sfu/wandisco-dev2dev
_______________________________________________
witty-interest mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/witty-interest

Reply via email to