Link to home
Start Free TrialLog in
Avatar of llj45
llj45

asked on

convert VB.NET to C#

Hi,
  Please convert this VB.NET code to C#.  Please try to keep the second line of code a single line of code.

Dim questionID As Integer
questionID = CType(Items.FindControl("lblQnum"), Label).Text

Thanks, LLJ45
Avatar of Rajkumar Gs
Rajkumar Gs
Flag of India image

int questionID = 0;
questionID = ((Label)Items.FindControl("lblQnum")).Text;

Try
http://www.developerfusion.com/tools/convert/vb-to-csharp/

Raj
ASKER CERTIFIED SOLUTION
Avatar of michael_madsen
michael_madsen
Flag of Denmark image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of llj45
llj45

ASKER

Hi, Raj
  I already tried the developerfusion converter web site.  It doesn't work on this code.
  You can set up an example to see what I mean.
Thanks, LLJ45
Avatar of llj45

ASKER

thanks!