Write String to Spreadsheet

Hello,
I have two Booleans and an alphanumeric string that I want to write to a spreadsheet.  The attached code changes the two Booleans to strings, builds an array comprised of the two Booleans and the alphanumeric string and writes the data in a spreadsheet.  After that, it tells the VI what state to go to next where a similar process is repeated.  I am using a VI called Write_String_to_Spreadsheet_File.VI that I downloaded from this Website to write to the spreadsheet.  There is only one problem.  The Write_String_to_Spreadsheet_File.VI appends data to the end of the file.  I need to be able to replace specific data if values change without changing previously entered values.  Is there anyway that I could modify my code to specify the exact row in the spreadsheet to write to?
Thanks,
Drew
Attachments:
WRITE_TO_SPREADSHEET.LLB ‏98 KB

Hello,
Here is the code I've generated.  It uses the FILE INFO.vi to determine whether or not the file exists. 
1) If the file does not exist, the WRITE_STRING_TO_SPREADSHEET_FILE.vi creates the file and writes the data entered in the first row of the spreadsheet. 
2) If the file exists, the Read_Text_from Spreadsheet_File.VI should read in the data from the spreadsheet file and the WRITE_TEXT_TO_SPREADSHEET_FILE.vi should write the new data in the first row of the spreadsheet.  This part isn't working, and I can't figure out why.
Can anyone propose a solution?
Thanks,
Drew
P.S.  I tried to solve my problem by using the Index Array.vi in case 2 to address each cell to be rewritten in case 2 (r0,c0, r0,c1, and r0,c2) individually, but it didn't work correctly either.  I think the problem there was the fact that the output of the Index Array.vi becomes 2 diminsional whereas the output of the Build Array.vi is one diminsional.
Attachments:
WRITE_TO_SPREADSHEET.LLB ‏178 KB

Similar Messages

  • Write array to spreadsheet string

    Hi,
    I have 3 numeric arrays and 1 string array.  I am try to use the function write array to spreadsheet string.  What is the easy way to do this, since I have both numeric and string, I can't create a 2d array directly?
    Yik
    Kudos and Accepted as Solution are welcome!
    Solved!
    Go to Solution.

    It depends how you want the file to store the data.
    Attached is an example of two methods mentionned above.  You can change the formatting so that you have the data on the same line or different lines.
    There are many solutions depending on exactly what you want to accomplish.
    --- didn't expect to see so many replies so quickly ---
    Most people recommend converting the numeric array to string array first.  I offer an alternative   or a choice of both.. 
    Attachments:
    exampleOfWriteDiffArrayToSprdsht.png ‏28 KB

  • Arrray of strings into spreadsheet

    hi,
    Pls help me in writng the array of strings into spreadsheet (.xls)
    I have 3 or 4 different 1d array of strings and i have to put each array of string into differnet coloumn....
    thanks

    Does it have to be an actual xls file or will a CSV (which can be read directly from Excel) file do?
    If a CSV will work, combine all of the arrays into a 2D array.  You will likely need to use Transpose 2D Array.  Then use Array to Spreadsheet String with a comma as the delimiter.  Write the new string to a text file.
    There are only two ways to tell somebody thanks: Kudos and Marked Solutions
    Unofficial Forum Rules and Guidelines

  • Write traces to spreadsheet file mis-wiring

    I want to extract the data from the DSC database based on a user- or program- defined time range and write that data to a text file. I have the first stages of that set up here, but there is a broken wire (cluster type) that I don't understand what about it is broken.
    According to the help dialog for "Write Traces to Spreadsheet File", the trace information cluster shown in the vi should be correct. But it is not and is marked as a false connection. What is wrong???
    Attachments:
    extract_data_from_database_-_sent_to_NI.vi ‏52 KB

    Change the order of the objects inside your cluster. Disconnect the cluster wire from the write traces to spreadsheet file vi. Right click on the terminal and select create constant. Turn on the context help window and move the cursor to both wires and note the order of the items in the datatype of the wire.

  • Write string (7 chars), int16, sgl into binary file and read it in C

    How to write write string (7 chars), int16, sgl, string (5 chars) into binary file and then read it in C ?
    Total 18 Bytes file (binary) should be created.

    Hi,
    this could be done that way:
    You have to make sure the strings have their correct length!
    Best regards,
    GerdW
    CLAD, using 2009SP1 + LV2011SP1 + LV2014SP1 on WinXP+Win7+cRIO
    Kudos are welcome

  • Abap class to write strings

    Hello all,
    Does anybody knows if exists an abap-class to write strings in SAP console ? I'm looking something similar of  System.out.println() in JAVA.
    Regards,
    Arthur

    Hi
    as per my knowledge its not possible to write ABAP classes in console like java..but we can run the programs through the console for that follow the below syntax..its very time consuming process..
    check the below syntax it may be helpful for you...
    C:\Program Files\SAP620\SAPGUI\rfcsdk\bin>startrfc
    RFC command line interface
    Syntax :
             startrfc [connect options] <function options>
    where
    function options =
              -F <function module
              -E <parameter>=<value>
              -T <table name>,<width>,[r=<file>][,w=<file>]
                 where <file> is a path name to read from (r)
                 or write to (w) the internal table.
                 If <file> is -, stdin or stdout is used
    Thanks&Regards
    Sreenivas Pachva

  • FileUtilsService Write String New Line Character

    Hi All,
    SITUATION:
    Writing a custom log file using the Write String service operation.
    Everytime an event occurs, i want to insert a new line, with date time stamp, details etc.
    PROBLEM:
    In the "value" property of the "write string" service operation... im inputting my relevant data but dont know how to indicate a new line
    WHAT I TRIED:
    I've tried every form of new line character i know: \n, \r, <BR>, \u0000a, \u0000d, ACSII, CRLF, etc, etc... none of them works.
    WHAT I FEAR:
    the exact same situation as http://forums.adobe.com/message/2780658#2780658 ... with a fairly definite answer
    I'm hoping i dont have to go this LONG ugly scary route.
    WAY FORWARD:
    Your thoughts, answers, suggestions....
    Thanking you all in advance.

    if going the "executeScript" way....
    this code worked for me:
    ===========================
    import java.lang.String;
    String vLogEntry = patExecContext.getProcessDataStringValue("/process_data/@logEntry");
    String vLogEntry = vLogEntry + " \r\n";
    patExecContext.setProcessDataStringValue("/process_data/@logEntry", vLogEntry);
    =================

  • How to write strings with an underline on the TOP-OF-PAGE of ALV

    How to write strings with an underline on the TOP-OF-PAGE of ALV

    if u r using classes and methods it can be done
    but if u r using normal fms and then u have to use HTML_TOP_OF_PAGE but the drawback for this it cannot be printed when the report is printed .

  • Write string array into cfg file

    Hi, everybody.
    I faced the problem to write array into cfg file. I am trying to put many items in a key. It should look like
    [Section1]
    Key1=el_1, el_2,el_3,.............el_n.
    each element is string of 105 characters. Everything works fine when I save the only one el_1 or multiple for the  first time, however, when I am trying to update values in a key section some extra strings appear in a file. My VI is attached.
    Thanks in advance

    Do you realize that your spreadsheet string only writes the following:
    1111111111
      2222222222222222
     33333333333333333333
    The way you wrote your VI, it sends the entire string above to the value for Write Key.vi.
    Do you realize that value is for the data type only?  So I'm not sure what you want to do....
    Without describing the problem you are having, can you describe what you actually want to do?
    R
    Message Edited by JoeLabView on 07-22-2008 11:49 AM
    Attachments:
    confused.PNG ‏26 KB

  • Writing string into spreadsheet

    i am reading the serial data(in string format) and storing it in text file one by one .but i was not able to write the data in spreadsheet one by one...i am getting the result as last iteration value has been repeated iteration times.....eg If the last iteration value is 5 and it has iterated for 4 times...the output i m getting is 5 5 5 5....but expected result is 2 3 4 5....help me out in ths

    I am getting the proper result in wordpad..but i am not getting properly in ms excel.......
    Attachments:
    block diagram.png ‏147 KB
    expected result.png ‏164 KB
    result.png ‏149 KB

  • Write string to serial port ?

    Hello! Thanks all, who help me build up this attached VI !!!
    Small problem.
    In a few words: I received date from serial port, my VI work with it, and I want pass string “sting I need write to port” to serial port. (see attached VI).
    Data all time read from port and write to port.
    I know, how work serial VISA, but I don’t know, how connect wire.
    And second question: how insert subVI in VI from .llb?
    Thanks!
    Mikhail.
    Attachments:
    string_to_serial_port.vi ‏170 KB

    Hi  Dai!
    Thanks for answer.
    I did as you said, but something  I did wrong.
    Please, look at my VI. What is wrong?
    Mikhail.
    Attachments:
    string_to_serial_port.vi ‏171 KB

  • Anyone else having issues writting string "memo" fields to Access 2007-2010 or SQL Server Express 2008-2012?

    I have a data cluster that I am working to write to either Access 2007 thru 2010 and/or SQL Server Express 2008 thru 2012 all on a Windows 7 64 bit OS. Some of the elements are long strings that I put delimited data for the raw trace data. The fields can be 10's of KB long. With Access I cannot stuff any string >255char into the memo field. With SQL Server Express 2008R2 - 2012 I found that if the strings are >32767 they again fail to fill the memo fields. The Access write or reads work fine otherwise, just not the listed offending fields in the cases mentioned.  Anyone else having the issue or a solution?

    If the long string field has repetitive data, you might be able to compress it using GZIP to reduce it's size below the 32K limitation you mentioned.
    GZIP compress/uncompress of string using .NET
    Now is the right time to use %^<%Y-%m-%dT%H:%M:%S%3uZ>T
    If you don't hate time zones, you're not a real programmer.
    "You are what you don't automate"
    Inplaceness is synonymous with insidiousness

  • How to write in a spreadsheet after pushing a beam

    Hi @ all,
    I'm from Germany. Don't expect the best english, please.
    My problem is that I want to write data into a spreadsheet after pushing a button. Not continous but one time after pushing the button, however. And this must be able during a while loop is running.
    Into the while loop two xy-traces are displayed and after stopping the vi, these data were written in a spreadsheet. thats not the problem. But, as I wrote, I want to push a beam (sensing device ?) and than another three values should written in another sheet.
    best regards
    Message Edited by Topper_g on 06-21-2007 08:04 AM

    Set the button mechanical action to one of the latching modes. Then the button will reset to false immediately after it is read. This takes care of the one time save requirement.
    Connect the button to the select terminal of a case structure. In the true case save the data to the file. In the false case do nothing.
    Both the button and the case structure will be inside your while loop.
    Lynn

  • Write/read from spreadsheet file

    How to write and read bach 2D array from spreadsheet file?

    The Write to Spreadsheet File.vi and the Read to Spreadsheet File.vi that ship with Labview are fairly self-explanatory - also check the File I/O examples included with Labview.

  • Write STRING fields in SMARTFORM

    Hi folks.
    I'm trying to write a STRING field in a SMARTFORM but only the first 255 characters are writen in output.
    It's a resctriction? Is there any workaround?
    Helpfull ideas will be rewarded.
    Best regards.
    Thanks in advance.
    Valter Oliveira.

    No string fields.
    Made a workaround, like several 255 variables in a text element.
    Thanks.

Maybe you are looking for