[Gambas-user] Any method to show better the current row in a DataView Grid?
Rolf-Werner Eilert
rwe-sse at osnanet.de
Wed Jan 17 15:40:37 CET 2018
Am 17.01.2018 11:02, schrieb Constantin Teodorescu:
> Hello all,
>
> I'm evaluating Gambas3 (I have compiled and run 3.10 on a Linux Mint)
> and I check various things!
>
> Is there any hidden property that will show the current row in a
> DataView Grid, more than the bold row number in the left header?
>
> I have done something ugly to that, is there any othe more elegant
> method to achieve the same thing? :-)
>
> Public Sub PersDV_Activate()
> Dim numRow As Integer
> Dim oldText As String
> numRow = PersDV.View.Row
> If numRow > -1 Then
> oldText = PersDV.View[numRow, 0].Text
> PersDV.View[numRow, 0].Background = Color.blue
> PersDV.View[numRow, 0].Foreground = Color.white
> PersDV.View[numRow, 0].Text = oldText
> PersDV.View[numRow, 0].Refresh
> Endif
> End
>
> Thanks,
> Teo
>
>
There should be a property "single" or "row" for the way something can
be marked by the user by clicking on one row. Set this to True and then
make the last line the current line or set its "marked" property to True.
I do not have the time to check for it right now, so my answer is a bit
fuzzy, but this is how you might achieve it. Just from memory...
Regards
Rolf
More information about the User
mailing list