Why can't I use Get LV Class Default Value in a dynamic VI?

I am attempting to override a VI that uses "Get LV Class Default Value" and getting an error that I don't understand.  My parent class, "ANT Message Class", has two children - "ANT Command Class" and "ANT Response Class".  The children share a lot of data and functionality, including the factory pattern that the parent class' "Load Message Class" VI implements (see image).  I would like to override this VI with a Command version and a Response version, which would simply call the Message version with their respective classes overriding the dynamic input and output terminals.  However, I am getting the error "Front Panel Terminal 'ANT Message Class Out': Run-time type not propagated from dynamic input to dynamic output."
Not sure how to get around this one.  Any ideas?
Thanks,
-Jamie 
Solved!
Go to Solution.
Attachments:
Get LV Class Default Value in dynamic VI.png ‏179 KB

The To More Specific node is dealing with compile-type inference. In this case, you are loading a default instance from disk and then attempting to cast to the base Message class. However the type you are casting to is going to a dynamic output - this gives the compiler no assurances that the input class at run-time on the dynamic input will be the same as the output type; only that it will be a type at the top of the hierarchy. Dyanmic dispatch inputs/outputs must be the same type to guarantee some form of type safety.
You need the Preserve node there so that you can guarantee the class at both dynamic dispatch terminals will be the same type.
However this is probably not the best mechanism for a factory method. Factory methods should ideally be static; their job is to provide an instance of the right type (e.g loaded by path as per your example) and you don't need an instance of a class to do that. The only reason I can think of to over-ride said functionailty in a dynamic dispatch method is to provide some form of custom construction for the creation of the type. If all you are creating is an instance with nothing but the default private data then there is no reason to over-ride in the child classes.
EDIT: Another post collision. nathand is on the money with this one.

Similar Messages

  • Opening Build Specificat​ion - Error 7 occurred at Get LV Class Default Value.vi

    I recently ported my project to a new PC. Everything seems to run fine uncompiled, and I am able to build an executable without issue. However, my build specification shows up in the project explorer with question mark next to it. When I try to build again or edit the properties I get a popup with the information below:
    Error 7 occurred at Get LV Class Default Value.vi
    Possible reason(s):
    LabVIEW: File not found. The file might be in a different location or deleted. Use the command prompt or the file explorer to verify that the path is correct.
    =========================
    NI-488: Nonexistent GPIB interface.
    Complete call chain:
    Get LV Class Default Value.vi
    AB_UI_Initialize_Framework.vi
    AB_UI_FRAMEWORK.vi
    AB_Item_OnDoProperties.vi
    AB_Item_OnDoProperties.vi.ProxyCaller
    LabVIEW attempted to load the class at this path:
    <Empty Path>
    I've seen messages from people getting the same error when trying to run a compiled executable, but mine actually runs fine. I am just unable to open the build specification to rebuild or edit its properties.

    This application is for a Windows machine, and I am not using the Report Generation Toolkit. However, I shut down my computer last night and when I booted it up this morning my Build Specification now opens fine and I am able to edit it. My only thought as to why it occured in the first place is that I had added several files to user.lib and instr.lib and restarted LabVIEW, but it appears that it required my computer to be restarted as well.

  • Error 7 occurred at Get LV Class Default Value.vi only in my executable for Print Report - LV 2010 SP1

    I have a program written which uses the print report function. Everything works fine in the uncompiled code, my report prints just fine. I can compile my project all the way to a full installer. When I run the executable I get the error:
    Error 7 occurred at Get LV Class Default Value.vi
    With the following text:
    Possible reason(s):
    LabVIEW:  File not found. The file might have been moved or deleted, or the file path might be incorrectly formatted for the operating system. For example, use \ as path separators on Windows, : on Mac OS X, and / on Linux. Verify that the path is correct using the command prompt or file explorer.
    =========================
    NI-488:  Non-existent board.
    Complete call chain:
         Get LV Class Default Value.vi
         NI_report.lvclass:New Report.vi
         print report.vi
         EMS V3.0 streamline.vi
    LabVIEW attempted to load the class at this path:
    H:\InMotion\EMS\builds\EMS_01\Emissions Analyzer\EMS.exe\1abvi3w\vi.lib\Utility\NIReport.llb\Standard Report\NI_Standard Report.lvclass
    "EMS V3.0 streamline.vi" is my main vi, "print report.vi" is the subvi that creates and prints the report based on all the information sent to it. I get no warning when I compile this to an executable. I already tried repairing both LV SP1 and the report generator toolkit. No change after I compile to an exe.
    Any help would be appreciated. Thanks.
    Garrett Herning

    Ok, I tried that... and now I get an error when I try to compile to an executable... This is right at the end of the build and will not let me build an executable.
    Error:
    An error has occurred. Expand the Details section for more information.
    Details:
    Visit the Request Support page at ni.com/ask to learn more about resolving this problem. Use the following information as a reference:
    Error 7 occurred at Invoke Node in 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.ProxyCaller
    Possible reason(s):
    LabVIEW:  File not found. The file might have been moved or deleted, or the file path might be incorrectly formatted for the operating system. For example, use \ as path separators on Windows, : on Mac OS X, and / on Linux. Verify that the path is correct using the command prompt or file explorer.
    =========================
    NI-488:  Non-existent board.
    Method Name: Linker:Write Info To File

  • Why can we only use 1 release class for overall Release of Purchase Req?

    Hi,
    After realizing that it would be beneficial to use more than one release class for overall release of Purchase Requisition with classification, in use with release groups for overall release, I now ask if someone knows why SAP has chosen to only allow 1 release class for overall release of Purchase Requisition?
    In my scenario I would like Release group US, used for release strategies for US-plant to be able to use 1 release class with a specific set of characteristics.
    For example class REL_PREQ_CLASS_OVERALL_VALUE_IN_USD including a characteristic PR_TOTVAL_USD looking at CEBAN-GFWRT. The chosen currency for this characteristic would be USD.
    I would then like to allow Release group FR, used for release strategies for FRANCE-plant to use another release class with another set of characteristics.
    For example class REL_PREQ_CLASS_OVERALL_VALUE_IN_EUR including a characteristic PR_TOTVAL_EUR looking at CEBAN-GFWRT. The chosen currency for this characteristic would be EUR.
    In this way the release strategies for the respective release groups US and FR, could maintain their overall limit values in their respective release strategies in their own currencies.
    1. Observe that I do not want to use the same Release class for both release groups for overall release, even though I know that this is currently the only allowed option, as far as I've understood.
    2. Observe that I do not want to specify the two characteristics PR_TOTVAL_USD and PR_TOTVAL_EUR for overall value in the same release class, as this would lead to double maintenance for a large number of release strategies. Also consider the maintenance when new countries with new currencies want release strategies.
    3. Observe that I only want to use overall release.
    What I'm trying to avoid is having to continuously translate local business USD overall value limits to limits in the currency chosen for the overall value characteristic. If this for example is specified in DKK, this would lead to a need to adjust the overall value limits as soon as the exchange rate between USD and DKK changes in the system.
    Please consider this simple example:
    Local requirement is that USD purchase requisitions should be blocked when the USD value is above 1000 USD. However in my release strategy I would have to maintain a value of >5365 DDK, if DKK is chosen as the currency for overall characteristic.(e.g exchange rate 5,365).
    Next month the currency exchange rate in the system between USD and DKK has changed, and therefore I would have to go into CL24N and maintain the value to reflect the new exchange rate between USD and DKK. Lets say it has gone up to 5,435. I would now have to maintain a value of > 5435 DKK in my release strategy to correctly reflect the local business requirement of 1000 USD.
    So if anyone could please explain why SAP has taken the decision to make the Release class for overall release client specific that would be much appreciated and awarded accordingly. Also if you have any suggestion on how I could obtain the above scenario on maintaning overall value limits in different currencies than that would be awarded to.
    BR Jakob F. Skott

    You can give feed back to Apple from the iTunes drop-down menu in the iTunes menu bar..
    You can also contact the iTS Customer Service from the links on this page - http://www.apple.com/support/itunes/store/
    MJ

  • Why can''t I use the Servlet class?

    I am trying to build a Servlet by extending HttpServlet. I imported java.io.*, javax.servlet.*, and javax.servlet.http.*. When I compile, it tells me the Servlet packages were not found in import. I am using JDK 1.3. What version do I need to use these packages?

    Ok, and you are sure the name, servlet.jar, is in the classpath, and not just the path to the servlet.jar. E.g.
    mypath/servlet.jar (and not just mypath/).
    It must be a classpath problem if it can't find the package. You could also try to compile your class with the -classpath option:
    java -classpath mypath/servlet.jar *.java
    and see if that helps. Or look inside the servlet.jar to verify that it has the packages you need.

  • Programmatic save of LVOOP class default value

    Hi!
    I've been stuck on this littel issue for some time now, maybe I can't see the wood for trees, maybe my intention is utopic
    Here is what I want to do: retrieve class default value from an existing *.lvclass (no prob so far), modify it in some sort of configuration programme and then save back the default value to this (or another) *.lvclass file.
    The only intended editing is about changing the default value, not more, not less.
    I have tried some VI server magic but failed (LabVIEW crashed)
    Any suggestions?
    Cheers
    Oli
    Programming languages don't create bad code, programmers create bad code....
    Solved!
    Go to Solution.

    Well, I do understand this issues for controls, but I'm sill struggling to transfer this to the LVOOP issue.
    Here's what I used to understand about loading class default values:
    I'm able to load a class default value dynamically from disk as long as inheritance is set right (--> PlugIn Architecture).
    So lets say I have a parent class A which has two children B1 and B2. So using the Get LV class default value.vi I'm able to load classes dynamically and cast it to class A (To More Generic Class). This way I can also load Class_B1.lvclass and Class_B2.lvclass and use dynamic dispatch.
    Now, if B1 and B2 have basically the same class private data (let's say a Boolean) that only differs in default value (true/false) I have a similar case for loading as what I'd like to do for saving.
    Having said that: maybe my intention should be be better described as modifying an existing class default value and save it as a new class.
    I guess there is a reason why NI did not implement the saving part... just need to understand why
    Oli
    Programming languages don't create bad code, programmers create bad code....

  • Why can't I use WebCT chat with my computer?  I get the 'spiral of death' every time I try to type in my chat.  I have a feeling it has to do with compatibility issues between Java and Tiger.

    Why can't I use WebCT chat with my computer?  I get the 'spiral of death' every time I try to type in my chat.  I have a feeling it has to do with compatibility issues between Java and Tiger.

    Hi Elizabeth,
    Do your Mac meet any of these requirements?
    http://www.wvnet.edu/services/webct/requirements.html
    From this it appears to be PC only!???
    http://sourceforge.net/projects/awebctcclient/files/Pancake%20%28it%20own%20proj ect%20now%29/Pancake%20Console%20V1.0.0/PancakeConsole-1.0.0-src.zip/download
    Can you provide any more info on which bersion or file you have?
    Can you tell us why you need this for your use?

  • Why can I not use the channel name, which is obtained from the function of DAQmx Task, as the input of the channel name for the function of Get Channel Information of DAQ?

    Why can I not use the channel name, which is obtained from the function of DAQmx Task, as the input of the channel name for the function of Get Channel Information of DAQ?

    Not a lot of details here, but my guess is this isn't working for you because you are wiring in the task to the Active Channels Property and not the actual Channel Name. I have attatched a screenshot of what I believe you are trying to do. The Task has 2 channels in it, so I need to index off one of the channels and wire it into the active channels input of the Channel Property node. Then I can read information about that channel
    Attachments:
    channel_name.JPG ‏69 KB

  • When downloading a pdf file I get a message that I must download Adobe Reader. When I do that I am told that it is already installed. Why can't I use it if it's already installed. I-Mac OsX 9.3

    When downloading a pdf file I get a message that I must download Adobe Reader. When I do that I am told that it is already installed. Why can't I use it if it's already installed. I-Mac OsX 9.3

    g -
    I was able to fix the problem with some help from Apple. Whenever I last downloaded Reader, I apparently didn’t complete the process by accepting the Reader contract. I was able to go right to that point in the process and complete the installation. The messages that I needed Reader but it was already installed were quite confusing. It would have been nice if the Adobe installation process that I was re-trying this morning had been able to detect a partial installation. The Troubleshooting page almost had me doing some ridiculous things that wouldn’t have helped.
    MP

  • Why can't I use my VTone I just purchased from Verizon Market as my phone ringer?  It game me an option to mark it as my default ringer but when I go to 'settings' it only gives me the same generic ringtones, how do i get my new ringtone to use?

    Why can't I use my VTone I just purchased from Verizon Market as my phone ringer?  It game me an option to mark it as my default ringer but when I go to 'settings' it only gives me the same generic ringtones, how do i get my new ringtone to use?

        I like to customize my phone with ring tones too! Let’s get this working for you.
    Did you purchase the ring tone on our website or on the phone?
    If it was purchased online the ring tone is sent to you in a message and you need to save the ring tone first http://bit.ly/PKUfUg and it is saved as a ring tone you can go in and set it as your default ring tone http://bit.ly/R5Xa4o.
    If the ring tone was purchased on the phone you just need to go into your ring tone to set it up http://bit.ly/R5Xa4o.
    Hope this is helpful. Keep me posted if you need further assistance.
    John B
    Follow us on Twitter @VZWSupport

  • It just don't make sense you say ICloud backs up my IPad so why can't I use the extra Gb then then who did I pay to get what I thought was GB to use on my IPad?

    It don't make sense then why sell the extra GB for the IPad I paid $100 thinking I use it for the extra storage who sold it to me? I thought it was apple I'll have to re check that!!! I'm disappointed for sure.if ICloud is for backup the why can't you use it for storage too!!!

    iCloud is for backup. It cannot magically change your device's hardware or storage capacity.
    "If you upgrade or renew your storage but no longer need it, you can cancel. If you cancel your storage plan within 15 days of an upgrade or within 45 days after a yearly payment, you can contact Apple for a full refund. After this period, you can downgrade your storage for the following year."

  • TS4268 Why can't I use my existing email for Face Time on my IPad?

    Why can't I use my existing email in Face Time and Instant Message?

    Do you have another Apple ID by any chance? There are many, many discussions about this message that you are getting. Here is one where it seems that these users were able to resolve it.
    https://discussions.apple.com/thread/4023754?start=0&tstart=0
    There are many other past discussions as well. Maybe you can find some help here as well.
    http://www.google.com/search?q=imessage%20email%20address%20already%20in%20use
    Or maybe something in the Apple support article will help.
    http://support.apple.com/kb/TS2755

  • User-defined object problem,why can't I use?

    as follows:
    UObject.java
    package test1;
    public class UObject
    private String num;
    public UObject()
    public void setNum(String num)
    this.num=num;     
    public String getNum()
    return num;     
    Test.java
    package test1;
    public class Test
    public static void main(String args[])
    UObject U=new UObject();
    U.setNum("Squall");
    System.out.println(U.getNum());
    UObject[] U=new UObject[5];
    for(int i=0;i<U.length;i++)
    U.setNum(String.valueOf(i));     
    for(int i=0;i<U.length;i++)
    System.out.println(U[i].getNum());
    error:
    java.lang.NullPointerException
    why can't I use?please tell me why?thanks.
    ps:in Test.java's comments can run./**/.

    Please use code formatting tags in future! http://forum.java.sun.com/features.jsp#Formatting
    It would be easy to find the problem yourself if you printed out a stack trace e.g.
    public static void main(String args[])
    try
    UObject U=new UObject();
    U.setNum("Squall");
    System.out.println(U.getNum());
    UObject[] U=new UObject[5];
    for(int i=0;i<U.length;i++)
    U.setNum(String.valueOf(i)); 
    for(int i=0;i<U.length;i++)
    System.out.println(U.getNum());
    catch( Exception e )
    e.printStackTrace()
    }Tho code doesnt look lke it compiles to me!

  • Why can't I use adobe flash player to open attachments

    Why can't I use adobe to open attachments - have downloaded latest version but still get a black page

    You're probably using IE11. This is a known problem with Internet Explorer 11, which Microsoft has been aware of since October 18 when they released their latest "untested" browser. The pages can't recognize the browser, so they don't recognize any of the plugins, like Flash Player. So far, Microsoft has made NO indication that they have any plan to fix it soon.
    Microsoft's recommendation is to use Compatibility View for affected pages, and "pretend" you're using an different browser. Trouble with that is it has seen limited success at best, and you have to individually enable it for EVERY page that has problems.
    I'm not big on "pretending" so I recommend actually using another browser, at least until Microsoft gets their act together and fixes IE..
    Firefox (from Mozilla)
    Opera (from Opera)
    Safari (from Apple)
    Chrome (from Google)
    ANY of those will work where IE11 won't, with the Flash Player Plug-in (For all other browsers), and Chrome doesn't even need that because it has its own Flash Player plugin built in.

  • Why can't i use command F in Notes?

    Hi all, i recently upgraded my to a newer macbook. i used to be able to use command f to search my notes. i'm now using 10.8.2  and for some reason i can't search/find. i hit 'command f' i get the bleep sound. when i look at Edit > Find > Find, the word find is greyed out.
    what should i do? i've tried googling and searching for a solution but the work 'notes' is too broad and so it brings up loads of irrelevant stuff.
    thanks
    shane

    Hi, thanks but no good. can you see how the 'command f' function is greyed out in the image below? why can't i use that 'Find' function? the box you've identified does a broad brush search to see if any of my notes contain a word but don't identify where the words are within the note. i have some notes with 10's of thousands of words.
    does anyone know how i can use the traditional 'Find' function?

Maybe you are looking for