[Gambas-user] Quickie on SELECT
Fabien Bodard
gambas.fr at ...626...
Sun Feb 8 16:28:33 CET 2015
well :-/
sometime we have old belief
this work fine
Public Sub _new()
Dim toto As String = "titi"
Dim tati As String = "titi"
Select Case toto
Case tati
Print "ok"
End Select
End
2015-02-08 15:16 GMT+01:00 Tobias Boege <taboege at ...626...>:
> On Sun, 08 Feb 2015, adamnt42 at ...626... wrote:
>>
>> Does anyone know if you can use an EVAL in a CASE selector?
>> e.g. SELECT hSomething
>> ...
>> CASE EVAL(hSomething.SomeArray.Exisits(hSomething.Value))
>> ...
>>
>
> This only makes sense if the Exisits method returns a string, or am I
> getting your idea wrong here?
>
>> (I am just being too lazy to try it)
>>
>
> Haven't seen this much laziness in a while :-)
>
> $ ./select-case-eval.gbs3
> Args.Count = 1
> $ ./select-case-eval.gbs3 arg
> $
>
> Apparently it works (and why wouldn't it, since Case hObject.Symbol is
> possible and in a Symbol_Read() you can do anything).
>
> Regards,
> Tobi
>
> --
> "There's an old saying: Don't change anything... ever!" -- Mr. Monk
>
> ------------------------------------------------------------------------------
> Dive into the World of Parallel Programming. The Go Parallel Website,
> sponsored by Intel and developed in partnership with Slashdot Media, is your
> hub for all things parallel software development, from weekly thought
> leadership blogs to news, videos, case studies, tutorials and more. Take a
> look and join the conversation now. http://goparallel.sourceforge.net/
> _______________________________________________
> Gambas-user mailing list
> Gambas-user at lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/gambas-user
>
--
Fabien Bodard
More information about the User
mailing list