1) how to assign name to Universal Library function TIN and VIN? or 2) how to provide headings in measurement file?

I am using a USB-TEMP-AI board from MCC with Labview 8.6
This necessitates using VInDLL.vi and TIn.vi to read my signals.
When I log using "write to measurement file", I would like headings
above the data such as:
           Tcold.in, Tcold.out, Thot.in, Thot.out, Flow.cold, Flow.hot
instead I get:
            Untitled, Untitled 1, Untitled 2, etc.
For some cases I need scaling, after which I get headings such as:
            Scaled (Scaled), Scaled (Scaled) 1, Scaled (Scaled) 2, etc.
How can I fix this?
Thanks,
Jon Snyder

One way is to use an NI data acquisition board and then you would probably be using the DAQ Assistant which would create the column names for you. A second way would be to just not use the Write to Measurement File and use one or more of the lower level file write functions (i.e. Write to Spreadsheet File) and write the column headers separately. The last way, would be to make sure the data from the mcc function is a waveform data type and set an NI_ChannelName attribure to what you want before passing the data to the Write to Measurement File.
This question has been asked numerous times and code for setting the attribute has been posted numerous times.

Similar Messages

  • How to Provide search Help for files on Application Server

    Hi Guys,
                   Can anyone tell me How to Provide search Help for files on Application Server. I have put a file name on selection screen. I want to give search help for files on application server.
    Thanks & Regards.
    Harish.

    Hi Harish,
    Use the following code,
    tables sxpgcotabe.
    data: lt_execprot LIKE btcxpm OCCURS 0 WITH HEADER LINE,
            w_filepath(60)       TYPE c, --> length depending on your Directory path.
      SELECT SINGLE *
        FROM sxpgcotabe
             WHERE name = 'LIST_DB2DUMP'
               AND opsystem = sy-opsys.
      IF sy-subrc <> 0.
        SELECT SINGLE *
          FROM sxpgcotabe
               WHERE name = 'LIST_DB2DUMP'
                 AND opsystem = 'UNIX'.
        IF sy-subrc <> 0.
          MESSAGE e000 WITH 'External operating system command '
                            'LIST_DB2DUMP not found'.
        ENDIF.
      ENDIF.
      sxpgcotabe-parameters = p_filepath. --> provide the directory path.
      CALL FUNCTION 'SXPG_COMMAND_EXECUTE'
           EXPORTING
                commandname                   = sxpgcotabe-name
                additional_parameters         = sxpgcotabe-parameters
                operatingsystem               = sxpgcotabe-opsystem
           TABLES
                exec_protocol                 = lt_execprot 
           EXCEPTIONS
                no_permission                 = 1
                command_not_found             = 2
                parameters_too_long           = 3
                security_risk                 = 4
                wrong_check_call_interface    = 5
                program_start_error           = 6
                program_termination_error     = 7
                x_error                       = 8
                parameter_expected            = 9
                too_many_parameters           = 10
                illegal_command               = 11
                wrong_asynchronous_parameters = 12
                cant_enq_tbtco_entry          = 13
                jobcount_generation_error     = 14
                OTHERS                        = 15.
      IF sy-subrc <> 0.
        MESSAGE e000 WITH text-e01 p_filepath.  "Directory failed
      ENDIF.
    Loop round the directory list, split each line up into a line table
    and get the last data for each line, should be the filename
    Then build the dirlist.
      REFRESH t_dirlist.
      LOOP AT lt_execprot.
        REFRESH t_dirline.
        SPLIT lt_execprot-message AT space INTO TABLE t_dirline.
        DESCRIBE TABLE t_dirline LINES w_nolines.
        READ TABLE t_dirline INDEX w_nolines.
        MOVE t_dirline-data TO t_dirlist-filename.
        APPEND t_dirlist.
      ENDLOOP.
    Here you will get all the files in the directory mentioned in Application server.
    For displaying them as a Search help use the FM '/BMC/ZPOPUP_GET_VALUE'
    Pass the Internal table to this FM.
    Regards,
    Paul.

  • Converting Units in LabView and specifying sampling rate with Universal Library functions

    Hi,
    I am having trouble converting units in LabView 7.0 and having it write to a file / output on a chart in Nm instead of in volts.  I can't seem to find any straightforward instructions, eventhough it seems like a simple task. 
    Another task that would seem rather simple is changing the sampling rate with the XAIn program from the Universal Library for LabView (this is version 5.40).
    If anyone could help me out, I would greatly appreciate it - I have tried other sources without much luck!
    Thanks
    Jenna

    Are you really needing to change units or do you need to scale the voltages read from your sensors? If it's scaling, it would be trivial to set this up in mAX or with the DAQ Assistant if you were using an NI board. Since you are not, then you could use the Scaling and Mapping Express VI. The y axis of a chart is just a label. You can use the text tool to change it to anything you want.
    I have no idea how to change sample rate for your board. Have you asked the vendor?

  • Data reading and writing problem? how to set " Read from Measurment File express.vi​" 's readout datasize?

    Dear all,
    I want to use Labview to process a data.
    Now I have a array in a text file.
    this array is very very big. which is at least row*col = 6 * 100000;
    the column size always 6,
    but the row size is ramdom, some times is very big, like bigger than 65535,
    when I use "read from measurement file express.vi" to read this file, the array I could get always 6*5339, I don't know why. the column size is always 5339.
    and then I delete the 1st row of the array and then write into a txt file via "write measurement file express. vi", it takes a very long time. almost computer has no response. after a while, no file was creat to record the data.
    is there an efficient way to process such big data file and store the processed file into a new file
    thank you very much
    Jack
    Message Edited by weichengatech on 03-09-2006 12:00 AM

    Hello,
    There’s no real efficient way to read the file if you don’t
    know exactly how many rows of data you have. 
    Your going to just have to read a row at a time and add the results to
    the end of an array (granted for the clever programmers there are some more
    efficient ways to do this than just with ‘build array’).  I would start by asking you how much
    information you know about the file and what the exact structure of it is (i.e.
    is it a binary file, a tab delimited file, or a LVM file)?  Could you provide a screenshot of the code
    you are running? If you provide a little more information on the file structure
    we might be able to contribute some additional information.
    Look forward to hearing back from you-
    Travis M
    LabVIEW R&D
    National Instruments

  • HT1751 I did all of the above and at the "Consolidate files" screen I clicked "ok" then it sayd "copying files failed. the file name was invalid or too long" and I had to click "OK"  I cannot consolidate the files to transport  to my external harddrive -h

    I would like to backup my itunes to my external hard drive
    I did all the steps up to "organize Liberary" which at this point I checked the box and the clicked"ok"
    it then said "copying files failed.  The file name was invalid or too long" "OK"
    It will  not let me consolidate the files so I can transfer to my external hard drive
    what am I doing wrong - any suggestions?
    thanks,

    Are you using consolidate files to bring in stray files to your main iTunes Media folder before backing up, or to copy the media folder to the external drive as part of backing up? If it is the latter then you are taking the wrong approach. See this user tip.
    Run my script Unconsolidated on the library. It will show you the remaining unconsolidated files which might give a clue as to which files iTunes is having a problem with. You can consolidate selected files in batches (select, right-click) as opposed to trying to do everything in one go. Alternatively you could try moving the remaining unconsolidated files with ConsolidateByMoving as long as this step is a precursor to a backup..
    tt2

  • Can you download all of your iTunes match account onto your computer?  I screwed up my iPod that had the entire library on it and the computer that had the hard copies of the files on it blew a hard drive.  I need to get the files back from iTunes Match.

    Can you recover/download all of your iTunes Match account onto your computer?  I synced the iPod that I had the entire library on to a new computer and lost almost all of my music.  The old computer that had the library on it blew a hard drive and I can't sync the iPod back to the old computer.  Everything is in iTunes Match, but can I load it onto my computer, so I can get it back on my classic iPod?

    If you had iTunes Match before all this happened, yes. Just log in, activate iTM and download the music. If you did not have iTunes Match prior to these incidents, no, it can not help you.
    You should also be doing regular backups of your personal data to an extnal HDD. If you had a backup hue could simply restore it.

  • How to provide security to a file.

    Hi Experts,
    We have a web application and we open the word file, excel file, wri file.. from a jsp using sendRedirect method. these files are opening in a browser. once we close the applciation, if we have the file link open in a browser we are able to open the file directly. But we want file to be open only from the web application.
    If any one know who to achieve, please reply.
    thanks,
    swpana soni.

    suppose you have a button in a jsp page , by clicking that you get an excel file opened in a new window (with a different url).
    if you use that url alone ,then also you get that file opened. and you want that to be happened.
    if(request.getRequestURL() ==expected page ( I mean the page with the button) )
    response.senRedirect(content);
    I think this will will solve that issue. and no need to edit web.xml also.

  • Using an external DLL with "Call Library Function"

    Hi!
    I am trying to use an external DLL which is used from Visualbasic & Delphi:
    http://www.keb.de/common/tools/KEBCOMDriver.zip
    the protKEB.dll accesses the serial port to control an KEB frequency
    inverter.
    Unfortunatly there is no prototype header file for the DLL (no help on that
    from KEB).
    I only have a VisualBasic example program which works with the DLL.
    (Unfortunatly I am no Visual basic expert)
    To initialize the com port I have to use the function: setprotproperties &
    getprotproperties
    they are declared as:
    'Setting the protocol properties
    'ctrl is a pointer to a data structure of type tProtProperty
    Declare Sub setprotproperties Lib "protkeb.DLL" (ctrl As Any)
    'Reading the protocol properties
    'ctrl is a pointer to a data structure of type tProtProperty
    'the desired protocol is entered in ctrl.prottype before calling
    Declare Sub getprotproperties Lib "protkeb.DLL" (ctrl As Any)
    and tProtProperty is:
    Public Type tProtProperty
    ProtType As Long 'Type of Protocol (tProt)
    TimeOut As Long 'ALL protocols
    Baudrate As Long 'ANSI, HSP5
    Comport As Long 'ANSI, HSP5
    Flag As Long 'ANSI, HSP5: 01 = Sendslow
    / IP: 01 = UDP
    Port As Long 'IPort number
    Txtlen As Byte 'IP : length of following
    text or 0
    txt As String * 100 'IP : IP-Address or name
    (maximum length)
    End Type
    I already tried to use a cluster with tProtProperty entries as an Input for
    the function
    setprotproperty in a call library function with:
    Parameter Type : Adapt to type
    Data Format: Pointer to Handle
    but I always get an "exception within external code....."
    What am I doing wrong?
    How does a cluster & a "call library function node" look like that works?
    Any help is really appreciated!
    thanks
    tom
    ,-Thomas Kerberger Physikalisch-Technische Bundesanstalt-.
    | Abbestr.2-12 D-10587 Berlin fon: +49-30-3481338 |
    | mailto:[email protected] fax: +49-30-3481386 |
    `--------Labor 7.33 Messung thermischer Energie---------'

    Thomas,
    LabVIEW cannot call a DLL that has structures directly, you will need to create either a wrapper DLL or CIN that will take in all of the data individually construct the structure, and send it to the DLL function.
    For more information on what a cluster looks like in native code, I would suggest creating a simple cluster, creating a Call Library Function Node on the block diagram with a cluster input. Then right-click on the Call Library Function Node and choose "Create .c file". This will generate the data structure for the cluster and give you a better feel for it. I would then suggest going to the Using External Code in LabVIEW manual that can be found in the LabVIEW Bookshelf (Start»Programs»National Instruments»LabVIEW 6»LabVIEW Manuals or »LabV
    IEW 6.1»Search the LaBVIEW Bookshelf).
    There is also the following: Developer Zone: Passing a Variety of Data Types from DLL to LabVIEW.
    Randy Hoskin
    Applications Engineer
    National Instruments
    http://www.ni.com/ask

  • Help to make opencv's dll and LabVIEW's Call Library function node understanding each others

    Hi, i have a little problem trying to use a C++ opencv's dll in labview. I wrote a really simple and stupid dll just to try to understand how it works the call library function node. Here the header code:
    #ifdef GENERICDLL_EXPORTS
    #define GENERICDLL_API __declspec(dllexport)
    #else
    #define GENERICDLL_API __declspec(dllimport)
    #endif
    #include "stdafx.h"
    #include <opencv2/core/core.hpp>
    #include <opencv2/highgui/highgui.hpp>
    #include <iostream>
    #include <string.h>
    #include <stdio.h>
    #include <opencv/cv.h>
    #include <opencv/highgui.h>
    // Questa classe è esportata da Generic DLL.dll
    class GENERICDLL_API CGenericDLL {
    public:
    int Summ(int a, int b);
    int Sott(int a, int b);
    int opencv(int a);
    // TODO: aggiungere qui i metodi.
     and here the .cpp:
    // Generic DLL.cpp: definisce le funzioni esportate per l'applicazione DLL.
    #include "stdafx.h"
    #include "Generic DLL.h"
    #include <opencv2/core/core.hpp>
    #include <opencv2/highgui/highgui.hpp>
    #include <iostream>
    #include <string.h>
    #include <stdio.h>
    #include <opencv/cv.h>
    #include <opencv/highgui.h>
    using namespace cv;
    using namespace std;
    // Esempio di variabile esportata
    GENERICDLL_API int nGenericDLL=0;
    // Funzioni esportate.
    GENERICDLL_API int Summ(int a, int b)
    return a+b;
    GENERICDLL_API int Sott(int a, int b)
    return a - b;
    GENERICDLL_API int opencv(int a)
    const string ind = "C:\\Users\\sviluppo\\Desktop\\Tuli.bmp";
    const string ind_2 = "C:\\Users\\sviluppo\\Desktop\\Tuli_Gray.bmp";
    //Mat image;
    return 5;
    i can call all the three simple functions in labview with this easy code. No problem at all. If i uncomment the line "Mat image;" the call library function node doesn't work and i receive the error:
    "The library specified for this node cannot be found or cannot be loaded. Right-click the Call Library Function node and select Configure, then choose the correct library name or path."
    I think that is a problem of dependencies between opencv libraries but i dont know how to manage this. Any ideas?
    Thank you for yours time,
    Francesco.

    Hello Francesco,
    I'm having exactly the same problem as you. I created a DLL that I can easily access from LabView. If I add one line and include "imgproc.hpp" (the only one I need), then LV gives me the same error you had. I read the thread Loura linked to, but I don't see how people actually take care of the dependecies (Klemen's examples did not work for me for the same reason, even though I recompiled the .cpp). Could you explain in detail what you did to make it work?
    Thanks

  • How to give the application server file path in the module pool programming

    Hi,
         Could somebody help me how to provide the application server file path in module pool programming once the logo is uploaded to sap system.
      For eg I have imported a logo name ‘owens’ into sap system by using transaction ‘se78’; now I need to call the path in the below url,
    if container2 is initial.
    CREATE OBJECT CONTAINER2
      EXPORTING
        CONTAINER_NAME              = 'PICTURE_CONTAINER2'.
    CREATE OBJECT PICTURE2
      EXPORTING
        PARENT = CONTAINER2.
    CALL METHOD PICTURE2->SET_DISPLAY_MODE
      EXPORTING
        DISPLAY_MODE = CL_GUI_PICTURE=>display_mode_fit_center
      EXCEPTIONS
        ERROR        = 1.
    CALL METHOD PICTURE2->LOAD_PICTURE_FROM_URL
      EXPORTING
        URL    = " ? "
      EXCEPTIONS
        ERROR  = 1
        Others = 2.
    endif.
    Thanks in advance
    Deepu

    hi Deepu,
    Use FM '/SAPDMC/LSM_F4_FRONTEND_FILE' for fetching the data from the application server path/presentation server path
    Regards,
    Santosh

  • How to provide f4 help

    Hi guys,
      here i amproviding some sample code.
    requirement is uploading data from xl to internal table.
    problem is how to provide f4 help for file name.
    using cl_gui_frontend_services.
    type mismatching is occuring.
    DATA:  wa_filename1 TYPE file_table,        "for method
           wa_filename2 TYPE rlgrap-filename,   "for function module
           wa_data TYPE alsmex_tabline.
    DATA:    t_data TYPE STANDARD TABLE OF alsmex_tabline.
    DATA:      file_count TYPE i.
    selection-screen begin of block bk1 with frame title text-001.
    parameters:p_fname type char10.
    selection-screen end of block bk1.
    at selection-screen on value-request for p_fname.
    Method to get filename
    CALL METHOD cl_gui_frontend_services=>file_open_dialog
      EXPORTING
        window_title            = 'Excel file name'
      CHANGING
        file_table              = P_fname
        rc                      = file_count
      EXCEPTIONS
        file_open_dialog_failed = 1
        cntl_error              = 2
        error_no_gui            = 3
        not_supported_by_gui    = 4
        OTHERS                  = 5.
    start-of-selection.
    LOOP AT p_fname INTO wa_filename1.
      wa_filename2 = wa_filename1.
    To upload excel to internal table
      CALL FUNCTION 'ALSM_EXCEL_TO_INTERNAL_TABLE'
        EXPORTING
          filename                = wa_filename2
          i_begin_col             = 1
          i_begin_row             = 1
          i_end_col               = 2
          i_end_row               = 88
        TABLES
          intern                  = t_data
        EXCEPTIONS
          inconsistent_parameters = 1
          upload_ole              = 2
          OTHERS                  = 3.
    *ENDLOOP.
    u can expect more rewards.

    my code sample:
    REPORT  zcobkk01.
    * INCLUDES                                                             *
    INCLUDE zcobkk01top.
    * SELECTION-SCREEN                                               *
    SELECTION-SCREEN BEGIN OF BLOCK b1 WITH FRAME TITLE text-001.
    PARAMETER p_file TYPE string OBLIGATORY.
    SELECTION-SCREEN END OF BLOCK b1.
    * AT SELECTION-SCREEN                                                          *
    AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_file.
      CLEAR it_file.
      CLEAR v_rc.
      CALL METHOD cl_gui_frontend_services=>file_open_dialog
        EXPORTING
          window_title            = 'title here'
          initial_directory       = 'C:'
        CHANGING
          file_table              = it_file
          rc                      = v_rc
        EXCEPTIONS
          file_open_dialog_failed = 1
          cntl_error              = 2
          error_no_gui            = 3
          not_supported_by_gui    = 4
          OTHERS                  = 5.
      IF sy-subrc EQ 0.
        READ TABLE it_file INDEX 1 INTO p_file.
      ENDIF.
    * START-OF-SELECTION                                                   *
    START-OF-SELECTION.
      PERFORM load_file USING p_file
                             CHANGING it_return.
      IF it_return IS NOT INITIAL.
        PERFORM validate_data USING it_return
                              CHANGING  it_input
                                        it_err.
        PERFORM display_err CHANGING it_err.
      ELSE.
        WRITE: 'Error'.
      ENDIF.

  • Nested library function call

    Is it possible to create a DLL using the LabVIEW Application Builder from a VI that already contains a library function call?
    Thanks,
    mlloyd

    Hi mlloyd,
    This should definitely possible. If you dig deep enough, you'll realize that some of our VIs such as DAQmx, signal analysis, etc, use Call Library Function Nodes, and you can build those into a dll, so this should work.
    Best regards,
    -Sam F, DAQ Marketing Manager
    Learn about measuring temperature
    Learn how to take voltage measurements
    Learn how to measure current

  • Issue using DLL / library function node

    Hi All
    I am using labview 8.2 / 8.0
    I am writing a wrapper DLL to convert compex data types of a DLL to simpler ones for labview intefacing.
    I have read the forums on all related items and could not find a solution.
    I have cut my code back to basics and I am still getting error 1097 with 8.2 and a crash with 8.0
    The error occurs as follows:
    1) Start labview, open the vi.
    2) Run vi - everything works (so far the wrapper DLL I am writing call just does a simple open handle and close handle on a driver dll).
    The handle is passed back to the vi, and everything is good.
    I can re-run the application numerous times and it always works
    3) IF I close the vi, but not labview and re-open I get the following:
    Labview 8.0 crashes on closing the vi
    Labview 8.2 does not crash, but I get error 1097 if I re-open and run the vi.
    So it seems like it's almost working but the issue comes on the release of the dll from one invocation of the vi to another.
    I don't know what the error is, but I've tried everything I can think of! Any suggestions would be appreciated!
    Note: I am not passing any arrays at the moment, but I am passing one unsigned 32 bit int pointer. I declare a constant for this in the call, so there is something for the pointer to use, and it seems to return the data ok.

    Hi Kaem,
    Thanks for your reply.
    I have written C++ standalone programs that link to the DLL and these work fine. I have even called my wrapper DLL from a C++ program and that too works fine (just to check if the wrapper would cause issues there). I have a hunch that it is actually the DLL that my wrapper is 'wrapping' that is causing the issue, but I guess I don't know for sure.
    The difference (IMHO) is that these C++ programs all run through once and then exit, so everything works fine. However if they load the DLL and unload it and try to load it again, maybe there would be an issue. I think labview is doing this.
    The reason I think labview does something funny with the DLL after you exit a VI (but not labview) is because labview crashes in 8.0 when the VI is closed (8.2 is ok, but the next DLL invocation fails when the VI is reopened), so something must be happening at this point - and I think it's an ungraceful unload of the DLL.
    Also, I've noticed that I cannot overwrite my wrapper DLL with a new version until I exit a VI - so labview is definitely doing something on VI close - it's releasing some lock on the DLL.
    I don't use any consts in my code  - sorry if I indicated that. What I have is a U32 constant in labview, and I connect that to the input of  the library function node, and pass it as a pointer. And the DLL writes into this then. Are you saying that a labview constant cannot be used as an input to a function and passed as a pointer ? What should I use instead, a control?
    Note: while writing - I just tried that - same error -  so I don't think this is it.
    I'm willing to take any and all suggestions!!
    Cheers
    John

  • Call Library Function Node

    When using a call library function node and program is exited, I get a "has encountered a problem and needs to close" error having to do with ntdll.  It doesn't stop the program from running correctly, but it is annoying.  Any ideas?
    Solved!
    Go to Solution.

    Sorry about the missing information.  This is my first post.  I am using Labview 2010 on Windows XP SP3.  I am including a stripped down version of my application that will produce the same error along with the project file.  This only happens when the application is built into an executable.  It will also occur if the application is closed before FindWindowA is called.  I'm also including a file containing the error that comes up.  I appreciate all the help.
    As to why I'm doing this myself?  Ignorance would be the best explanation.  A machine supplier gave me a VB program to communicate with his application.  I used the same functions in Labview to do the communication and it worked great.  I thought that was pretty cool. 
    Attachments:
    FindWindowA Test.vi ‏25 KB
    FindWindowA Test.lvproj ‏7 KB
    FindWindowA Error.JPG ‏28 KB

  • I wrote a assignment in the microsoft word 97-2003 doc but by mistake replace in the same name but with different thing . how can i retain my orinal file which was as Basel III and Banking law

    i wrote a assignment of almost 2500 words in the microsoft word 97-2003 doc but by mistake replace  a table only in same name  . how can i retain my orinal file which was as Basel III and Banking law

    Hey Christian
    Thanks I havn't seen that post, busy trying it now but no luck so far.
    I defined it in the second one (Content Management - Utilities - MIME Types).
    Tried it now in NWA, no luck either . . .
    What I noticed is no matted what it is defined as in NWA or Content Management, the properties of the mht file still shows Binary File (application/octet-stream)
    Any ideas?
    Regards
    Antonette

Maybe you are looking for

  • Mail is no longer opening.

    The mail application used to work. Since I attempted to sync my documents and contacts, it now won't work. It starts freezing and I am forced to endulge in the option "force quit". Can anyone tell me what to do? Thanks.

  • HP Officejet Pro 8500 A909a Series email address to print from an ipad

    Where do I find the email address for my HP Officejet Pro 8500 A909a Series so I can use my new HP app on my ipad for printing from my ipad to my printer? Tina This question was solved. View Solution.

  • Issues after thunderstorms

    Every time we have a thunderstorm we have major issues with our airport extreme. We have to reset it to the factory settings and start over, and sometimes that doesn't work the first time. For example it went out last night. I got it back up and runn

  • Discovery issues with airport extreme and issues with airport utility

    I lost about 3 hours with connection issues while trying to add a second airport express. The airport Utility couldn't find any of the units anymore. After aging a couple of years and checking lots of forums (many suffered the same problems) I found

  • How can i find my ipad in my flat?

    How can i find my ipad in my flat?