Problem with using Const

EDN Admin

Well-known member
Joined
Aug 7, 2010
Messages
12,794
Location
In the Machine
Hello:
I have a class that uses a private constant:
Private Const ciMaxLogin as Integer = 5
One of the classs methods uses this variable:
psError = String.Concat("Password is case-sensitive and does not match. Please try again. (Attempt: ", MyClass.ciNoLogin.ToString, " of ", MyClass.ciMaxLogin.ToString, ")")
When I try to compile, this raises a warning:
Access of shared member, constant member, enum member or nested type through an instance; qualifying expression will not be evaluated.
What am I doing wrong?
Venki


<br/>

View the full article
 
Back
Top