Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Click event
Message
From
06/07/2005 23:47:45
Hilmar Zonneveld
Independent Consultant
Cochabamba, Bolivia
 
 
To
All
General information
Forum:
ASP.NET
Category:
Coding, syntax and commands
Title:
Click event
Miscellaneous
Thread ID:
01029812
Message ID:
01029812
Views:
54
Probably another beginner's question.

For some reason, I can't even code something simple in a button Click event. When double-clicking on the button, I get the code:
public void btnAceptar_Click(object sender, System.EventArgs e)
{
}
But even when inserting a simple variable declaration within the brackets, I get lots of errors:
public void btnAceptar_Click(object sender, System.EventArgs e)
{
private double CostoUnitario;
}
The first error says that a "}" was expected.

Commenting this line, everything compiles fine - so I don't think it is an issue of mismatched brackets, for example.

Any ideas, what can be wrong?
Difference in opinions hath cost many millions of lives: for instance, whether flesh be bread, or bread be flesh; whether whistling be a vice or a virtue; whether it be better to kiss a post, or throw it into the fire... (from Gulliver's Travels)
Next
Reply
Map
View

Click here to load this message in the networking platform