Labview 8 export strings

Hello,
I tried to convert an Labview 7.1 VI into 8.0.
for localizing, i am exporting strings an reimport them.
since i upgraded, i get an error when i reimport the strings.
Even if save the VI,Export and imediately re-import the strings i get an error message.
Is this a bug in LV 8.0 or is my source-VI corrupt?
I would be glad about every hint

Hello,
in general, this should work with LabVIEW 8 as well. I am attatching a translator application, which was originally built in LabVIEW 6.1. You can try to translate your VI with this application - actually it is a LLB containing the source code - and see if it works with your VI.
regards
Ingo Schumacher
Systems Engineer Sound&VibrationNational Instruments Germany
Attachments:
Translator_Application.zip ‏192 KB

Similar Messages

  • Import & Export Strings method

    Hi,
    I have a multilanguage application. I have used export & import
    strings methods. I have one .txt file for each language but when I
    modify something in my vi I must export all again and then modify the
    tags again for each language file... Is there a way that I can modify
    my vi and I don't have to export all again?
    Thanks,
    ToNi.

    As far as i know you need to export strings again only if you have made any changes on front panel.
    exported file is nothing but a xml file so that you can manually edit it instead of exporting everything again (helpfule if you have done very small changes on front panel)
    Tushar Jambhekar
    [email protected]
    Jambhekar Automation Solutions
    LabVIEW Consultancy, LabVIEW Training
    Rent a LabVIEW Developer, My Blog

  • [LV8.2] "Export string" (captions) strange behaviour

    Hi,
    I have 2 VIs. One was made with previous versions of LV (called A), and then re-opened and saved with LV8.2, the other was born in LV8.2 (called B). All is ok. I have some "system checkbox" controls in them, I didn't check the "show caption" and "show label".
    Their label and caption would be like "W 0", "W 1", ecc...
    Open A vi.
    Tools -> advanced -> export strings
    Export caption for control without caption? -> NO, I don't want
    Export block diagram strings? -> NO
    Save the file into "strings.txt"
    Now open the "strings.txt" with notepad, search "W 0", and it appear a string like:
    <CONTROL ID=79 type="Boolean" name="W 0">
    <PART ID=82 order=0 type="Caption"><LABEL><STEXT>W 0</STEXT></LABEL></PART>
    this last string would not be expected !!! it's an error, because I told him "No" in the first questin before.
    infact if I repeat the procedure with B vi, it only appears:
    <CONTROL ID=79 type="Boolean" name="W 0">
    and not also the other <STEXT>  !!!
    I don't know why happens this, is there any particular reason? maybe a general setting that I'm losing? The behaviour is not the same in the two vi.
    Thanks

    "export caption for control without caption?"
    If you turned on your caption at some point, then your control has a
    caption, whether or not it is visible.  The question is not "export
    caption for controls with hidden captions?"  If you never view the
    caption for the control, LabVIEW does not create a caption for a
    control.  For example, if you try to get the caption text using a
    Proprty node for a control where you haven't viewed the caption, it
    will generate an error.
    In the attached code, Caption1.vi has a control which the caption has
    not been viewed.  If you Answer no to the above question, you will get
    Caption1-1.txt.  If you answer yes, you will get Caption1-2.txt.  You
    may notice (in LV 8.5 this behavior is there, I do not knwo about 8.2),
    that the control now shows its caption and has hidden its label.  The
    VI also got saved.  I can now not get Caption1-1.txt to generate again.
    In Caption2.vi, I viewed the caption, then hid it again.  Answering no
    to the question above, I got caption2-1.txt.  Answering yes, I got
    Caption2-2.txt.  The two files are the same becuase the control always
    had a caption.
    Attachments:
    captions.zip ‏8 KB

  • Parse export strings

    Hi,
    LabVIEW has a feature to export strings from the front panel to file.
    You go to Tools->Advanced->Export Strings...
    Is there any library out there that parses the output of that file?
    It's not XML so XML parsers refuse to do it. I was wondering if anyone is aware of a library availible in LabVIEW to parse this file?

    Hi Maciej,
    I also thought of finding some way to 'fix' the XML, as you say it would be useful to use an external XML parser, but I couldn't find any existing tools. To make a general one will take some effort! Below is a list of some known issues with the current format compared to XML, it may help you in case you want to make such a tool.
    Missing root element
    XML dictates exactly one root element per XML file. However during our VI strings export, we create multiple root elements per file. Solutions:
    Wrap the individual VI entries into an additional root element
    Use one individual XML file per exported VI 
    Missing quotes around attribute values
    Our VI string export violates the rule that attribute values must be quoted e.g. 
    <CONTROL ID=85 type="VI Refnum" name="StationVIPrototype"> correct would be: 
    <CONTROL ID="85" type="VI Refnum" name="StationVIPrototype">
    Elements that are not properly closed
    Some of our elements such as <NO_TITLE>, <CRLF>, <LF>, etc. are not closed, violating the requirement that all tags must be properly closed. This could easily be fixed by adding the missing forward slash at the end of the tag: <NO_TITLE/>
    Special case: FONT elements
    FONT elements are used as switches to toggle font properties. E.g. to turn a substring of a text bold, LabVIEW uses two tags, one to switch the bold property on and another one to revert the change. Example: This text is normal, <FONT style='B'>this text is bold<FONT predef=APPFONT> and this text is normal again.
    We can fix this by emitting the proper closing tag where the reverting extra tag used to be:
    This text is normal, <FONT style='B'>this text is bold</FONT> and this text is normal again.
    Elements with double angle brackets
    Single angle brackets are "escaped" to double angle brackets. E.g. if a VI description text reads x < y it will be converted to x << y. Similarly, our export creates double angle brackets when it encounters <B> or <I> elements.
    Unescaped entities cause XML parsers to fail, e.g. when it reads X & Y rather than X &amp; Y  -- other examples: less than, greater than, quotes (single, double)
    All the best,
    Ian S
    Applications Engineer CLD
    National Instruments UK&Ireland

  • Exporting string to csv keeping commas and new lines

    Hi there,
    I am exporting string to csv and have been removeing new lines and commas like so
    thing.toString().replace(/\n/g, '').replace(',','') ;
    how can I do this iwthout losing the line breaks and commas? I can't have them in atm because messes up the csv.

    JSON is for 'transfering' information that can be reassembled into number, string, array, object, etc. format afterwards.
    Excel can import CSV but it might not understand the complexity of the information. Tyically what you would do is serialize complex information with JSON, recieve it on the other side (wherever that might be) and then deserialize it. After you deserialize it using JSONs abilities to turn your information back into what is was (numbers, strings, arrays and object) it is up to you how you restructure the data for the format you choose.
    Your original intent of preserving CSV is best for Excel or OpenOffice Calc. You didn't mention your intent. JSON would package those (CRLF) \n's for you.

  • How to export string in CDATA with the jaxb xml writer?

    How to export string in CDATA with the jaxb xml writer?
    It read CDATA no problem but it is lost on write.

    Found it:
    ### THIS WORKS WITH SUN JAXB REFERENCE IMPLEMENTATION. ###
    (Not tested with any other)
    In the xsd, you must create a type for your string-like element.
    Then associate a data type converter class to this new type, which will produce CDATA tags.
    Then you must set a custom characterEscapeHandler to avoid the default xml escaping in order to preserve the previously produced CDATA tag.
    Good luck.
    -----type converter-----
    import javax.xml.bind.DatatypeConverter;
    public class ExpressionConverter {
         * Convert an expression from an XML file into an internal representation. JAXB will
         * probably have already stripped off the CDATA encapsulation. As a result, this method
         * simply invokes the JAXB type conversion for strings but does not take any other action.
         * @param text an XML-compliant expression
         * @return a pure string expression
         public static String parse(String text) {
              String result = DatatypeConverter.parseString(text);
              return result;
         * Convert an expression from its internal representation to an XML-compliant version.
         * This method will simply surround the string in a CDATA block and return the result.
         * @param text a pure string expression
         * @return the expression encapsulated within a CDATA block
         public static String print(String text) {
              StringBuffer sb = new StringBuffer(text.length() + 20); //should add the length of the CDATA tags + 8 EOLs to be safe
              sb.append("<![CDATA[");
              sb.append(wrapLines(text, 80));
              sb.append("]]>");
              return DatatypeConverter.printString(sb.toString());
         * Provides line-wrapping for long text strings. EOL indicators are inserted at
         * word boundaries once a specified line-length has been exceeded.
         * @param text the string to be wrapped
         * @param lineLength the maximum number of characters that should be included in a single line
         * @return the new string with appropriate EOL insertions
         private static String wrapLines(String text, int lineLength) {
              //wrap logic, watchout for quoted strings!!!!
              return text;
    ------in caller----
    Marshaller writer = ......
    writer.setProperty("com.sun.xml.bind.characterEscapeHandler", new NoCharacterEscapeHandler());
    -----escaper-----
    import java.io.IOException;
    import java.io.Writer;
    import com.sun.xml.bind.marshaller.CharacterEscapeHandler;
    public class NoCharacterEscapeHandler implements CharacterEscapeHandler {
         * Escape characters inside the buffer and send the output to the writer.
         * @param buf buffer of characters to be encoded
         * @param start the index position of the first character that should be encoded
         * @param len the number of characters that should be encoded
         * @param isAttValue true, if the buffer represents an XML tag attribute
         * @param out the output stream
         * @throws IOException if the writing process fails
         public void escape(char[] buf, int start, int len, boolean isAttValue, Writer out) throws IOException {
              for (int i = start; i < start + len; i++) {
                   char ch = buf;
                   if (isAttValue) {
                        // isAttValue is set to true when the marshaller is processing
                        // attribute values. Inside attribute values, there are more
                        // things you need to escape, usually.
                        if (ch == '&') {
                             out.write("&");
                        } else if (ch == '>') {
                             out.write(">");
                        } else if (ch == '<') {
                             out.write("<");
                        } else if (ch == '"') {
                             out.write(""");
                        } else if (ch == '\'') {
                             out.write("&apos;");
                        } else if (ch > 0x7F) {
                             // escape everything above ASCII to &#xXXXX;
                             out.write("&#x");
                             out.write(Integer.toHexString(ch));
                             out.write(";");
                        } else {
                             out.write(ch);
                   } else {
                        out.write(ch);
              return;

  • Imoprt/Export Strings in Translation Builder not working

    Hi All,
    I am new to Translation Builder.
    There is a form which is referring many other forms, when I am importing strings of main form in translation builder, its not importing all prompts and only 25 out of 500 prompts. May be it is not importing prompts from other referring form.
    Among above 25 prompts, I have imported translations from English to German (translation builder). But after exporting the translation and compiling the form in D folder, translated prompts are not visible in German language login.
    I am following the below steps:
    1. Created DB connection
    2. Created New project
    3. Right click > import strings
    4. Base language 'AMERICAN', character set 'WE8ISO8859P1', version ='1' form=form from 'US' folder. (this form also refers other forms which are available under resource directory)
    5. Right click on .fmb > add translation > translation language 'German' & Trns. character set 'UTF8'
    6. RHS double click on GERMAN UTF8 > ok (here its not importing only very few prompts)
    7. Provided translations > save
    8. Click on version > export string and exported to d folder.
    9. Logged in with German language.
    Now translations are not coming.
    Note: First time i am using translation builder.
    Please let me know if I am missing any step or any set is required etc..
    Many thanks..
    Soniya.

    Everything was done from scratch with V28.
    1. 10. 2013 v 16:14, Bob Bringhurst <[email protected]>:
    Re: Customized strings in iPad viewer not working?
    created by Bob Bringhurst in Digital Publishing Suite - View the full discussion
    That's odd. It worked for me when I tested it. Perhaps you should try moving the current xml file to a different folder, downloading a new version, copying and pasting, and rebuilding.
    Please note that the Adobe Forums do not accept email attachments. If you want to embed a screen image in your message please visit the thread in the forum to embed the image at http://forums.adobe.com/message/5728130#5728130
    Replies to this message go to everyone subscribed to this thread, not directly to the person who posted the message. To post a reply, either reply to this email or visit the message page: http://forums.adobe.com/message/5728130#5728130
    To unsubscribe from this thread, please visit the message page at http://forums.adobe.com/message/5728130#5728130. In the Actions box on the right, click the Stop Email Notifications link.
    Start a new discussion in Digital Publishing Suite at Adobe Community
    For more information about maintaining your forum email notifications please go to http://forums.adobe.com/message/2936746#2936746.

  • How can labview update the string control (text-edit box) after we have pressed the carriage return key on the keyboard during text-editing within that box?

    Dear readers,
    I have been trying to work out how to get labview to detect the event when a 'string' control has been modified, where the user has finished editing the string either by 1) pressing the enter key on the keyboard, or by 2) taking the focus away from the string control again. For example.. if I use the mouse to click on the string control and then I type 1234 into the box, I would like to have a routine that does something once the user hits the Enter key of the keyboard, or when the user takes the focus away from the string control again by clicking on something else. I would like the routine to respond even when the user didn't change anything in the text box (such as when we mouse-click on the edit box to go into edit mode, and then mouse-click on something else to remove the focus with no changes to the contents in edit-box).
    The purpose of my routine is to have a edit-box for a user to change for example the centre-frequency of a vector network analyser, so that the centre-frequency of the network analyser can change once the user finishes entering a new value in the text-edit box by hitting Enter key after the number is keyed in. Even if the user has clicked on the edit box, but changes their mind by mouse-clicking on something else to remove focus from the edit box, I would still like labview to detect the event when the control loses focus, so that the centre frequency can be updated anyway (to the same value that was already in the edit box).
    So far, I've tried set the string control option to 'limit to single line', so that I can try to scan for a carriage return .. '\n' ... pattern in the string. Unfortunately this doesn't work because labview doesn't seem to attach the '\n' to the end of that single line.
    Could someone please suggest ways to set a flag when a user hits Enter during text-edit mode of a string control, or when focus has been removed from the string control?
    While I've only described my problem for controlling a single control parameter on the gpib device, I'd like to make this feature work so that I can do the same kind of thing with other control parameters as well.
    Thanks so much in advance.
    Kenny

    Hi Kenny,
    instead of using the event structure, you can directly achieve to what you want by the KeyFocus property of the string control.
    - Enable Limit to single line option
    - Create the property KeyFocus in read mode and connect an indicator
    Each time you click on the string to modify it KeyFocus is True; when you click away or hit Enter KeyFocus is False.
    You can toggle your settings when KeyFocus changes from True to False.
    Alberto

  • Export strings - xstream

    I'm using the free package Xstream to export my objects to an XML file. Works nicely except one aspect. Since I'm i a non-english country some special characters may occur in strings in the object I export wich causes problem when the XML files are loaded on a different system than it was saved in. The classical UNIX - Windows ASCII table problem.
    So how can I make Xstream export in a system-independent format? Or more simply; if I have a String - how can I convert it to a String with escape sequences as in a properties file? And back.
    Pls
    /Tomas

    Ok, now I have tried a bit, but only on a Windows
    machine - no export to other systems.
    I have a couple of Q's:
    * If the XML is correctly formed, specifiyng a
    characther encoding, hen IE and FF should be able to
    disply it correctly?If your XML is correctly formed, specifies a character encoding and indeed uses that character encoding then both IE and FF should be able to display it (providing you have the correct fonts and those programs know how to use them).
    * Is UTF-8 extensive enough to be used together with
    special characters like � � � � � UTF-8 can encode every single Unicode character. Everything that has a unicode value can be encoded in UTF-8
    Reason for asking is that if my XML file has the
    following format:
    <?xml version="1.0" encoding="UTF-8" ?>
    <object-array>
    <string>Tecken � � �</string>
    You should check what file encoding is really in use: Use the HexEditor of your choice and check that every character in your file is represented by exactly one byte, except for �, � and �, which should take 2 bytes. If that's true chances are quite good that you're writing valid UTF-8. If every character uses two bytes (with the first byte usually beeing 0x00) then you're using UTF-16 encoding.

  • How let labview to verify string is in Scientific Notation.

    Hey all,
    I want labview to convert a spreadsheet string to an array. This is easy using the 'spreadsheet string to array' tool. The only problem I've got is that I get the string from a RS232 device and it is time critical.
    Example:
    If I read the data from the buffer it gives me:
    +1.50337800E+00,+1.70316300E+00 for two channels, this is converted and accepted
    if there is a small delay I get:
    +1.50337800E+00,+1.70316
    This will also be accepted because +1.70316 is also recognized as a number.
    How can program labview to check that every number it reads is according to the Scientific Notation?
    Thanks
    Solved!
    Go to Solution.

    Don_Phillips wrote:
    This regex seems to work for me for all the cases I tried:
    [+/-]\d+\.\d+[Ee][+/-]\d+
    Note that it is very restrictive and only follows the form of ±n.nnnE±mm
    If it was up to me, I'd fix the problem and not the symptom - but many times, it is NOT up to me.  MANY times there are artificial constraints (like the time allocated to fix the problem) so you just have to make a band-aid like this.  I get grumpy when I'm forced to program a workaround instead of a fix. 
    Bill
    (Mid-Level minion.)
    My support system ensures that I don't look totally incompetent.
    Proud to say that I've progressed beyond knowing just enough to be dangerous. I now know enough to know that I have no clue about anything at all.

  • How to export strings with "\"

    When I export a string with backslashes in it (eg. path name to a file) then when this file is imported at run time then backslashes '\' cause the import to fail. So for now I have to replace all "xxx\yyy" strings in exported file with "xxx\\yyy" and then import
    of such MODIFIED file goes OK.
    But this is tedious - is there another way to deal with it ?

    This is caused by the fact that the ASCII backslash character is the escape code specifier, and when the file is read by the import/export properties tool it is treated as such. If you have any character sequences in a string such as "\t" or "\n" these get interpreted as tabs and newlines within the string.
    To avoid this behavior when importing you will need to modify the strings in TestStand before exporting them to include the "\\" escape code set to the file. The caveat to this is once these values are read back from the file they will be interpreted as single backslashes. For instance, if you export "c:\\temp", and then import it back you will get "c:\temp". This is simply the nature of the Import/Export Properties tool.
    If you do not like the b
    ehavior of this tool in its shipping form, you can rebuild the "limitloader.dll" module to include the functionality that you want. Whenever you click the Tools>>Import/Export Properties menu selection, the MainSequence of \Components\NI\Tools\ImportExport.seq is being executed. This has a single step in it that calls the "DisplayImportExportDialog" function of the limitloader.dll. The source for the limitloader.dll can be found in the \Components\NI\StepTypes\Database directory.
    Jason F.
    Applications Engineer
    National Instruments
    www.ni.com/ask

  • Is there any method to compress a string in LabVIEW?

    Can we compress a string in LabVIEW?

    A string is a series of bytes representing ASCII characters. If you want to compress the amount of bytes it uses, here's an idea:
    Assuming your string uses a limited character set, you can convert your letters to a 7-bit (or even 6 bit, if you give up capital letters) represention of your own making (let's say that '0' [48 ASCII] is 27 in your representation and not 48), thus saving a bit (or 2) off each byte. You can use the String to Byte Array VI and then the Number to Boolean Array VI.
    Now you have an array of bits in which each 6 bits is a character. Break the array into groups of 8 bits, transform it back to a string and (hopefully) you've compressed the string by a quarter.
    When you want to decompress, you'll need to reverse the process.
    I haven't thought it through, and it probably needs some more work, but I think the basic idea should work.
    Try to take over the world!

  • Changing language of LabView controls?

    I just need confirmation. If LabView controls, like a graph, have a context menu then this context menu will be first in the language of the LabView IDE it was used with. If I build an application, then the builder includes the LabView RTE. This will also be the same language version as the IDE.
    Now , if I wanted to change the context menu language let's say to french, would it be sufficient for the user just to install a french version of the RTE? Is this correct?
    Solved!
    Go to Solution.

    You could you Import/Export strings from the menu bar to import other language text to the control on the FP.
    A programatic code for this is possible.
    -FraggerFox!
    Certified LabVIEW Architect, Certified TestStand Developer
    "What you think today is what you live tomorrow"

  • LabView 5.1 support of non-Englis​h languages

    I need to display the User Interface VIs in 5 European languages: French, Italian, Spanish, German and Portuguese. The problem is with the special characters of these languages.
    When I tried to copy a string containing a special character from a normal Word document to a Label in VI, the special character was displayed as ? (question mark)
    The same happened when I tried to use import string mechanism. The special characters in the imported strings were displayed as ?.
    Doesn't LabView support other languages?
    I saw that fonts has style (Such as Times New Roman) size and script which specifies the language.
    Maybe I can use fonts which are single language? If this is the solution, can you tell me where I
    can find such fonts.
    Thanks a lot!!!

    See yesterday's discussion for an answer.
    You are most likely copying unicode (M$ sence of it) characters from Word. Try to see it using HEX display option of the string control. If it has 2 bytes per symbol, so this is unicode I think.
    Next open exported strings file and check font names in it. Then check fonts actually set for the wrong label. Don't use label, use Caption instead, BTW.
    Discover which fonts you are using in Word document(unicode or not). Then you can try to export/save text as an ASCII file. I don't remember which is an exact file type for it in MS Word, Don't using it at all. Then open it in ,say notepad
    and try again.
    Another way to try is to use non unicode font to format your text and then try to copy it again (depends on Windows)
    As a quick workaround you can see if the first byte of symbol is 0 or not. If so, just remove it and you'll get normal english text. If not, you can use divisor number, which will be different for the each language. This is clear from the unicode table (2 bytes). If you'll reach this place, let me know I'll try to help how to calculate it.
    Hope that unicode is a reason of this behaviour.
    P.S. You can determine unicode by open fonts folder and double klicking to fonts. If you see boxes instead of some groups of symbols, so this is most likely unicode (I don't insist on correctness of this way. On my WinNT box this works).
    Sergey

  • Lenguage Conversion support for LabVIEW Linux

    Hi,
    Is it possible to switch from one lenguage to another based on user selection on LabVIEW Linux.
    The developed code will have option to choose lenguage.. Based on the lenguage selection my application should convert its lenguage.
    Is it possible in LabVIEW???
    is there any specific function???
    Kindly reply

    Absolutely.  There are lots of ways to do it.  I see three basic options, though:
    1.  Use import/export strings as mentioned here.
    2.  Use property nodes to change all the captions and displayed text on your front panel.  This would probably only be a good option for very small applications.
    3.  Use a third party tool like this.  This one is way over-priced, in my opinion.  But I thought I recalled seeing other third-party tools.

Maybe you are looking for

  • [SOLVED] Function Keys Problem On Dell Inspiron N5010

    Yesterday I bought a new laptop (Dell Inspiron N5010) and immediately installed Arch Linux on it. But when I launched the installation framework, I needed to use fdisk to partition my drive manually and to open another tty, ctrl + alt + f2 or up to f

  • Routine for Material Description in language DE instead of EN in report o/p

    Hi all, We need to display material description/text in terms of DE language insted of EN at o/p the report. It's a masterdata(0material) info object.There are many fields at report level,Only for this perticular field text only they want in DE langu

  • All my incoming messages are being marked as junk

    If I send a message to myself the filter marks mail as junk despite the advanced settings saying 'don't mark as junk people in my address book'. I reset the junk mail filter by accident. Anyone have any ideas. It was working OK up to that point

  • Purchase requistion number not been generated for material shopping carts

    Dear Experts, I am able to create a purchase requistion for text shopping carts once it is approved. For material if i create a shopping cart then status is showing approved(activated workflow without approval) but purchase requistion number not been

  • Mp3 player default prog

    How do you change the default program for a creative zen micro so when i plug it into my PC a program i have choose pops up