Jump to content



Photo

convert this C# code to VB

vb convert c#

  • Please log in to reply
4 replies to this topic

#1 Shane Ekanayake

Shane Ekanayake

    Neowinian

  • Joined: 07-September 11
  • OS: Win 7

Posted 31 March 2013 - 19:11

can anyone convert this C# code to VB. thanx

this.Invoke((MethodInvoker)(() => { timer3.Enabled = true; }))


#2 paul0544

paul0544

    Neowinian

  • Joined: 11-April 11

Posted 31 March 2013 - 19:15

This should be a reasonable starting point:

http://www.developer...t/csharp-to-vb/

#3 AnDom

AnDom

    Neowinian

  • Joined: 16-August 12

Posted 31 March 2013 - 21:12

Really had to work off one line of code... you are trying to convert anonymous delegates in C# into VB... which will only work in later version of VB.

#4 Eric

Eric

    Neowinian Senior

  • Tech Issues Solved: 11
  • Joined: 02-August 06
  • Location: Greenville, SC

Posted 31 March 2013 - 21:27

It should be
Me.Invoke(New MethodInvoker(
Sub()
  timer3.Enabled = True
End Sub))


#5 OP Shane Ekanayake

Shane Ekanayake

    Neowinian

  • Joined: 07-September 11
  • OS: Win 7

Posted 01 April 2013 - 05:18

It should be

Me.Invoke(New MethodInvoker(
Sub()
  timer3.Enabled = True
End Sub))


this worked perfectly thanx :-)



Click here to login or here to register to remove this ad, it's free!