[Gambas-user] What is missed: pointer to control name

Benoît Minisini g4mba5 at gmail.com
Wed Apr 25 14:14:00 CEST 2018


Le 25/04/2018 à 13:21, Rolf-Werner Eilert a écrit :
> 
> Hi Tobias,
> 
> I'm missing my first answer mail echo from the list. Hope you got it. If 
> not, please tell me and I'll resend it.
> 
> Further to our discussion, I had the idea of using .Tag in some way, and 
> this is what I found practical:
> 
> Public Sub GridView1_MouseDrag()
> 
>    With GridView1
> 
>      klasse = klassenbez[Val(.Tag) - 1]
> 
> When I copy this code into GridView2_MouseDrag() and 3 and 4 and so on, 
> I won't have to take care that klassenbez[] is changed appropriately. 
> But I still have to take care to change With GridView1 into GridView2 
> etc., so it's only half way done.
> 
> Your solution would help here, but is it really worth making a new 
> instance of a GridView just to look up its number for every MouseDrag? 
> In my answer I posted yesterday, the function I included your solution 
> in is only used seldomly, so I could live with it.
> 
> Regards
> Rolf
> 

Why don't you use control groups and LAST ???

-- 
Benoît Minisini


More information about the User mailing list