Ok, this one got me late last night:
I have a Polymorphic VI as a member of a LabVIEW Project Class Library that I want to form the API of the Class.
I don't want users to place specific instances of the methods in the Polymorphic VI on the BD, only to use the Polymorphic VI itself.
So I make the methods Private Scope and the Polymorphic VI Public scope... ...everything is all good running from source.
Build time comes around and I start getting build errors (see below of the description), it doesn't point to the Class Library directly, but as it turns out, the calling VIs of the Polymorphic VI.
An error occurred while saving the following file:C:\Users\developer2\Desktop\Private Polymorphic Class Members\[b]main.vi[/b]Visit the Request Support page at ni.com/ask to learn more about resolving this problem. Use the following information as a reference:Error 1502 occurred at AB_Source_VI.lvclass:Close_Reference.vi -> AB_Build.lvclass:Copy_Files.vi -> AB_Application.lvclass:Copy_Files.vi -> AB_EXE.lvclass:Copy_Files.vi -> AB_Build.lvclass:Build.vi -> AB_Application.lvclass:Build.vi -> AB_EXE.lvclass:Build.vi -> AB_Engine_Build.vi -> AB_Build_Invoke.vi -> AB_Build_Invoke.vi.ProxyCallerPossible reason(s):LabVIEW: Cannot save a bad VI without its block diagram.
So, after I was able to figure that out out I changed the calling method's scope from Private to Public and then everything was ok when building.
I then played some more today and found out that if I uncheck Remove unused polymorphic VI instances in the Build Spec, the error goes away.
I have attached some code if anyone wants to replicate it. Just toggle the VI.vi Scope from Private to Public or change the Build Spec as above.
Thoughts?
Is there a problem doing what I was doing? Or Is this a bug? If so, is it a known issue?
Cheers
-JG
Private Polymorphic Class Members LV2009.zip