I can\'t seem to find an answer out there for this. Here\'s the scenario: I have an ASP.NET project using C#. I\'m loading data (Username, email, etc...) from a sqlite datab
For this label:
In the code behind use (C#):
myLabel.Text = "my text";
Update (following updated question):
You do not need to use FindControl - that whole line is superfluous:
Label myLabel = this.FindControl("myLabel") as Label;
myLabel.Text = "my text";
Should be just:
myLabel.Text = "my text";
The Visual Studio designer should create a file with all the server side controls already added properly to the class (in a RankPage.aspx.designer.cs file, by default).
You are talking about a RankPage.cs file - the way Visual Studio would have named it is RankPage.aspx.cs. How are you linking these files together?