[Gambas-user] Setting TableView to Row
Stefano Palmeri
rospolosco at ...152...
Wed Nov 26 12:09:12 CET 2008
Il mercoledì 26 novembre 2008 10:11:04 Rolf-Werner Eilert ha scritto:
> Stefano Palmeri schrieb:
> > Il martedì 25 novembre 2008 11:06:27 Rolf-Werner Eilert ha scritto:
> >> Hi,
> >>
> >> is it possible to set TableView.Row from Code during runtime?
> >>
> >> Would be nice to make sure a certain row in the table is selected before
> >> the user begins working with it (e. g. to draw attention to this row).
> >>
> >> Just tried this
> >>
> >> IF po > -1 THEN mesListe.Row = po
> >>
> >> but nothing happened. It should trigger the click event of the TableView
> >> (mesListe) to show something, but I guess this isn't possible here, is
> >> it?
> >>
> >> Thanks for your ideas.
> >>
> >> Rolf
> >
> > I'm not sure that I perfectly understood, but it should be:
> >
> > TableView1.MoveTo(1, 0)
>
> Ok, I didn't perfectly express my thoughts :-) The question was how to
> get the event as if the user had clicked the row. If I do it by code the
> way you describe it, the click event isn't raised, so I will have to
> take care the other SUB is called then.
>
> > I use gb.qt.
>
> So do I...
>
> And do you know a way to scroll the tableview down to a new entry to
> make it visible WITHOUT selecting the row? I tried
>
> TableView.Row = 17 'no problem, works like MoveTo
> TableView.Current.EnsureVisible 'that runs good
> TableView.Row = -1 'that destroys the selection
>
> I just want to show the user "here is something new, please click me!"
> without setting the selection to the line.
>
>
> Regards,
>
> Rolf
>
Ok, I'm definitevely stupid because I don't understand.
I've attached a little example. There's a Tableview and a Button.
Pressing the button you add a new row, that is shown to the user but
NOT selected. So, run my example, and write some comments about "what to do,
when to do, where to do". Using the example we have a common project
to work on.
> -------------------------------------------------------------------------
> This SF.Net email is sponsored by the Moblin Your Move Developer's
> challenge Build the coolest Linux based applications with Moblin SDK & win
> great prizes Grand prize is a trip for two to an Open Source event anywhere
> in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/
> _______________________________________________
> Gambas-user mailing list
> Gambas-user at lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/gambas-user
-------------- next part --------------
A non-text attachment was scrubbed...
Name: table-0.0.1.tar.gz
Type: application/x-tgz
Size: 7943 bytes
Desc: not available
URL: <http://lists.gambas-basic.org/pipermail/user/attachments/20081126/e13bb7a9/attachment.bin>
More information about the User
mailing list