".Net Sports" <ba********@cox.net> wrote in message
news:11**********************@g44g2000cwa.googlegr oups.com...
I'm trying to initialize a variable inside a PageLoad in
visualstudio.net :
mytoday = DateTime.Now;
..and the error (or Build Task error) says : The name 'mytoday' does
not exist in the class or namespace 'myProject.myfilename'
when i try :
datetime mytoday = DateTime.Now;
I get an error : the type or namespace datetime cant be found
when doing:
string mytoday = DateTime.Now;
or:
int mytoday = DateTime.Now;
I get an error : cannot be implicitly convert System.DateTime to
string
????
.Net Sports
Seriously!
I'm not trying to be a complete bitch here, but you do need to hear this:
If your code above is problematic for you then you are not ready to code in
..NET. And especially not in C#.
You need to get some basic skills in OO and .NET. I would start with some
books and find tutorials on the web.
Oh, C# is case-sensitive. Did you miss that fundamental part of the
language?
Then again, I don't want to be too cynic. Keep on mastering C#. Coding adds
an extra dimension to your life. =)
Happy Learning
- Michael S