03-23-2009 12:28 PM
As a learning exercise, I am trying to use Visual Basic 2008 Express to convert a .NET web service into a .NET assembly for LabVIEW 7.1.
I followed the steps at http://digital.ni.com/public.nsf/allkb/DC2D2A5D64A485F686256D3F005EFB6
but I am not getting the .dll file with the constructor and methods I am expecting.
The webservice is located at http://www.webservicex.net/WCF/ServiceDetails.aspx?SID=19
I have attached the dll file I get. You'll have to rename it. Any pointers appreciated.
Solved! Go to Solution.
03-23-2009 01:27 PM
03-23-2009 01:41 PM - edited 03-23-2009 01:44 PM
Yep, you are right. VB2008 won't even support 1.1 .NET Framework.
I have located a PC with LabVIEW 8.5.1 installed and 3.5 .NET Framework. And LabVIEW still does not see the constructor and methods I expect, eg a constructor and methods to supply the stock symbol and return price.
03-23-2009 01:45 PM
nyc wrote:Yep, you are right. VB2008 won't even support 1.1 .NET Framework.
I have located a PC with LabVIEW 8.5.1 installed and 3.5 .NET Framework. And I am still not getting the constructor and methods I expect, eg a constructor and methods to supply the stock symbol and return price.
smercurio was rather implying that LabVEIW will have trouble with .Net 3.5 which is the version used by VB2008 and that it barely supports .Net 2.0. So what he was trying to say is that in order to create a .Net component for LabVIEW it may be benefecial to try an erlier version of VB such as VB2005 or maybe VB2007,
Rolf Kalbermatter
03-23-2009 01:53 PM
Ahhhhh. The light bulb just went on.
Thanks. I will give that a try.
03-23-2009 01:54 PM
Actually, I was referring to 7.1. I've only seen anectodal "evidence" that you can extend the spotty support of .NET 3.5 to newer versions of LabVIEW as well. Wouldn't surprise me, though.
nyc wrote:I have located a PC with LabVIEW 8.5.1 installed and 3.5 .NET Framework. And LabVIEW still does not see the constructor and methods I expect, eg a constructor and methods to supply the stock symbol and return price.
Well, I was able to load the assembly with my computer which is running 8.2 and has .NET 3.5 (as well as 2.0). I can see the constructors, but I have no clue as to how you're supposed to use the assembly.
03-23-2009 02:20 PM
Thank you both.
1.) I tried targeting VB 2008 to use 2.0 .NET Framework; instructions found at http://www.codeproject.com/KB/dotnet/targetnet2fromvs2008.aspx
2.) Followed the directions in the NI KB that I linked in my first post.
3.) Opened up LabVIEW 8.5.1 and called the .NET assembly file created in Step1 (which I had named Stockquote.dll). Looked in the getweather.vi at http://sine.ni.com/devzone/cda/epd/p/id/861 to learn how to do the calling.
Everything works!