VB.NET example...

Post your VB and VBA discussions here
Post Reply
Jay H
Posts: 0
Joined: Wed Mar 31, 2010 2:13 pm

VB.NET example...

Post by Jay H »

For the fun of it (Not sure if that should be legal) I ran my old VB6 application in Visual Studio 2008 and surprisingly, I got my old code to run in VB.NET after a few tweaks (Changes in the WinForm designer vrs the old VB6 Forms and also the CallBack functions had to have Delegates declared... )

My WinForms and VB.NET runs but I am getting an exception being thrown. VB.NET no longer supports the Variant datatype and the conversion tool converts them all to VB.Net Objects.

However, I'm getting some kind of exception with my new Objects and I think the call to ps5000RunBlock, which passes an type Object by Reference as the last argument to the call. My app seems to crash right there. This is under a very basic call, no channels set, no SigGen, No Trigger, I expect the thing basically to turn on, and then turn off.

Anybody got this figured out in VB.NET? I need to read up on more VB6 to VB.NET differences but I'm surprised at how easy it was to upgrade so far..


Post Reply