[Gambas-devel] New component for Gambas

Benoit Minisini gambas at ...1...
Thu Apr 3 15:44:06 CEST 2008


On jeudi 3 avril 2008, David Villalobos Cambronero wrote:
> Yes, they exists, but I need to use the same word but the type is not Date
> or Time is String
>
> an example:
>
> I need to do:
>
> Public Const Time as String = "TIME"
>
> But I cant use it since the word Time is a Keyword.
>
> I can do:
>
> Public Const Boolean as String = "BOOLEAN"
>
> But can't use Time or Date. Don't know why?
>
> Regards
>
> David
>

To force the compiler to interpret a token as an identifier, do that:

Public Const {Time} As String = "TIME"

And why defining constants, if datatypes as string are already constants?

-- 
Benoit Minisini




More information about the Devel mailing list