[Gambas-user] 'Public Enum' Question

Lord Quo lord.quo at ...626...
Tue Aug 24 17:42:50 CEST 2010


   Sorry, I wrote a terrible begginer error.

   This is my "correct" code:

Public Enum Automatic, Left, Center, Right, Fill, Justify, CenterAcrossSelection, Distributed, JustifyDistributed

   But Left and Right give me problems because they are reserved word. Can I use them in another form? In VB.NET I remember that the solution is use [Left] and [Right]

   Thanks.


From: Lord Quo 
Sent: Monday, August 23, 2010 7:17 PM
To: Gambas-user at lists.sourceforge.net 
Subject: 'Public Enum' Question


Hi all, I have a Public Enum declaration, but I need (or want) to use a constants named Left and Right:

Public Enum StyleHorizontalAlignment Automatic, Left, Center, Right, Fill, Justify, CenterAcrossSelection, Distributed, JustifyDistributed

But when I compile the project, Gambas give me an error:

'Automatic' unexpected
In class StyleEnums.module line 2

Can anyone help me?

Thanks

Daniel Rojas


More information about the User mailing list