Building resource name?

Hi Gang,
It's been a frustrating day.
I'm building an application driver for the PCI-6021 in native C++.  I'm using the DAQmx driver inside of it.  It appears that the driver needs C-type strings (array of type constant character) for  the "counter" specification.
All works well when I create the below and pass that to the function:
char My Counter[10] = "Dev1/ctr0";
But, I need to build the character array by casting and inserting integer variables for the device and counter numbers.
I can build strings that have the right text in them, but I haven't figured out how to cast that into a variable that will work with the command.
I know this is more of a C/C++ question, but I'll really appreciate all help.
Thanks,
Roger 
Solved!
Go to Solution.

Hi,
That doesn't help me.
I've also been able to build a string, inserting a char literal, using the "strcat()" function.  The problem is that the device number gets passed in as an integer (this driver must be compatible with existing software).  I can implicitly cast that by this code:
int MyIntArg = 1;
char MyChar = MyIntArg;
Then replace the character:
MyCounter = "Devx/ctr0" ;
MyCounter[3] = Mychar;
This compiles without error, but the counter doesn't run.  It only runs when character literals are used.  So far, I haven't figured out what the issue is.  When the function doesn't run, it returns -200220, which seems to be a type exception error.
I appreciate all help.
Roger

Similar Messages

  • What is the name of Report Builder Resource File

    Can Anybody knows what is the name of Report Builder Resource file and can it open in Oracle Terminal or not.
    Regard's
    Fahed

    How to create a new one.http://download-uk.oracle.com/docs/cd/B14099_19/bi.1012/b14048/pbr_arch.htm#i1005582
    http://download-uk.oracle.com/docs/cd/B14099_19/bi.1012/b14048/pbr_strt.htm#i1007097

  • Resource name field for target oracle table

    Hi,
    I want to build a generic interface that takes data from different similar structured flat files and loads to different target table (similar structure).
    I thought I will use the resource name field for both source and target and use variables to determine the source and target names during runtime.
    the problem is it runs fine at the source when i change the file names to load from but it fails at the target when i use variable to determine the target name.
    Did anyone try this earlier? if yes, can you please help? The error I got was 911 : 42000 : java.sql.SQLSyntaxErrorException: ORA-00911: invalid character
    and the query generated was
    insert into      SCHEMANAME.#PROJREP."v_generic_interface_target_name"
         COL1,
         COL2,
         COl3
    select     
         C1_COL1,
         C2_COL2,
         C3_COL3
    from     STGSCHEMA.C$_0DEMO1
    where     (1=1)
    Edited by: sriksd on May 7, 2010 6:51 PM

    Hi,
    Which KM you are using ?
    Try to use #PROJREP.v_generic_interface_target_name into Resource name of the table in the data models.
    Regards

  • VISA get resource name doesn't return USB serial ports

    We built an application on a computer that had an onboard serial port - COM1.  We put the option to change the COM port in the application.  We installed the built application on a computer with no serial ports, but installed a USB to serial converter that registers as COM3.  LabView does not see this port, even with a test application to return only the VISA resource names. 
    We have verified that the port is good with another program (a Modbus simulator) and installed the latest VISA runtime v4.41 separately to no avail.
    Any suggestions at further troubleshooting would be extremely helpful.
    Joe T.
    Solved!
    Go to Solution.

    My main application still isn't working, but now the small test ones are.
    Here's what I did:
    1.  Update my LabView 8.5 with the latest VISA runtime - 4.4.  This updated the Installer as well.
    2.  Added the MAX Installer to the build.
    3.  Added  the NI-VISA Configuration Support to the build
    4.  Uninstalled the application and reinstalled it with the new install volume.
    When I run MAX, COM3 shows up.  It also shows up in the Get Resources test application.  The simple test Modbus write program works, too.  I have a sneaky feeling that COM1 may be hard-coded somewhere in the main application; our next task is to find where the communications breaks down in our code.  The bottom line seems to be a lack of experience with the Application Builder on our part.
    Thanks to all who contributed!
    Joe T.

  • Old visa open, error code 1073807343, using VISA with a GPIB device, and VISA resource names

    Hi everyone,
    I'm trying to get a SRS model SR720 LCR meter (manual on this page) working with LabView, connecting it to my PC with an Agilent 82357A GPIB/USB interface (manual on this page). I'm running MAX version 14.0, and NI-VISA version 14.0. I'm running LabView version 13.0f2, 32 bit.
    I followed the directions on this page, and I'm pretty confident I can communicate with my LCR meter, because I can go to NI MAX->GPIB0::17::INSTR under "devices and interfaces", then go to the VISA test panel, go to the I/O tab, and I can enter a few commands from the SR720 manual, like changing the frequency, and I see the light on the LCR meter change to what I just told it to do. Here is a picture, just to illustrate it:
    Also, if I do the *IDN? command, it returns "
    9: Write Operation (*IDN?)
    Return Count: 5 bytes
    10: Read Operation
    Return Count: 41 bytes
    StanfordResearchSystems,SR720,08087,1.03\n
     So, that's good too. I also made the alias of this device "MyLCRmeter", but that shouldn't matter for now.
    Now I'm trying to get it to work in a more usable way. The SR7xx drivers that LabView found for me came with a couple sample programs, one called "Getting Started.vi". I tried to just simply see if it worked, changing the "instrument descriptor" field to "GPIB0::17::INSTR", since that's the one that seemed to be the right device in MAX. Here is a picture of the front panel of "Getting Started.vi":
    Trying to run it like this gave me this error (code -1073807343):
    Old VISA Open in SR715/720 Initialize.vi->SR715/720 Getting Started.vi
    Doing a bit of searching on these forums, I found these few threads (1 2 3), which seem to tell me that, since this program was written, the way you open VISA has changed. In the 2nd of those links, one guy said:
    You just have to replace the Old VISA Open function with the VISA Open that is on the Instrument I/O>VISA>VISA Advanced palette. When you do that, the wire to the string that was used for the resource name will be broken. Delete the string and make the actual VISA Resource Name visible on the front panel. Wire the VISA Resource Name control to the connector pane where the string control was (upper left connection).
    So, I went into the sub-VI Initialize.vi, and did that. Here is a picture of what the front panel and block diagram of the sub-VI Initialize2.vi (I changed the name in case I screwed things up, but I'm pretty sure the new one is the one being called by Getting Started.vi) looked like before I changed anything (you can see the Old VISA Open):
    and here it is after replacing that with the regular VISA Open, deleting the instrument descriptor string and replacing it with a VISA resource, and connecting that to the VISA Open:
    However, as you can see in the image above, and it seems like someone else had this problem in the 2nd thread linked above, I don't see my device listed in the drop-down menu (even if I refresh), only "LPT1" (I don't even know what that is):
    No, I wasnt able to select the visa resource from the pull down menu. somehow it seems disabled or something.
     If I just enter the VISA resource name from MAX manually, GPIB0::17::INSTR, and save and try running that, I get the error(code -1073807346):
    VISA Open in SR715/720 Initialize2.vi->SR715/720 Getting Started.vi
    So I'm not sure where to go from there, or why it's not in the drop down menu to begin with. I'm sorry if I've missed something but I've searched about as far as I can go. If I had to guess, maybe one thing could be that in MAX, under Tools->NI-VISA->VISA Options->My System->Conflict manager, I have both Agilent VISA and NI VISA enabled; I know sometimes problems arise from conflicts between different software fighting over the same hardware. Is this okay, or do I need to change it?
    Thank you and please let me know if there is any other code/screenshots I could provide that could help!

    Hi, I did indeed enable NiVisaTulip.dll under MAX->Tools->NI-VISA->VISA Options->My system->Passports->List of passports. Sorry, I should have mentioned that explicitly.
    By install as primary, do you just mean as it is here, where it is selected as the "Preferred VISA"?
    Or somewhere else? I installed NI-VISA first I believe, and then the Agilent one, and during the installation of the Agilent one, I'm pretty sure I made it not the primary. Here's what I have in the Agilent (it's called Keysight now) Connection Expert software:
    I also have this under the "Keysight 488 options" tab:
    Should that be checked? I don't actually know the role of VISA vs 488 here...
    What could I try?
    Thank you!

  • How to retrieve resource name in JSP page

    Hello,
    I have the following scenario:
    User wants a new resource to be provisioned to himself, he makes standard steps; chooses one resource from the list of available resources and sends a request. After that a summary page is displayed - my goal is to create an url to external application on that summary page (i.e. tjspRequestSubmitTiles.jsp) that should be displayed depending on the name of the resource, e.g. if user requests for a ResourceA - link appears, but when he requests for a ResourceB - link does not appear.
    So far I have created a link with a sample if statement - it works.
    My problem is how to make a real condition - retrieve the resource name that request deals with. Anybody know how to do that, which API to use etc.?
    Regards,
    Maciej.

    After adding the code to tjspProvideDataShowInfoTiles.jsp file, nothing has been improved, I am still facing the same result (on the console):
    RO: null
    It seems that file (tjspProvideDataShowInfoTiles.jsp) does not take part in the process.
    I have tried to pass some sample session attribute in tjspRequestVerificationTiles.jsp and this works, but I do not know how to retrieve resourceName in this file.
    I was trying to make some code retrieving resourceName in tjspRequestSubmitTiles.jsp, e.g.
    tcRequestWizardForm tcReqWizForm = (tcRequestWizardForm)session.getAttribute(requestWizardForm);
    String requestID = tcreqWizForm.getRequestID();
    ...and what to do now to retrieve resourceName?

  • Printing Resource Name Form View

    Hi there,
    I am using Project 2013 Professional on SP1 with all the updates applied.
    I am trying to print the resource name form so I can give all the business users involved in the project a list of thier tasks, when they are due, and how much effort is expected of them.
    I get the view fine.
    I then go +File +Print and get the print page but there is a message saying "Print is not currently available". I tried printing anyway, but as expected nothing happens.
    I can print some views but not others so it is not a generic printing issue, but seems to be related to not being able to print particular views.
    Has anyone experienced the same issue? Is there a fix? Am I doing something wrong?
    Thanks in advance
    Tony

    Backwardsit --
    Yup, I am experienced the same problem as you.  I cannot print the Resource Name Form view in Microsoft Project 2013, SP1.  If it were me, I would customize the Resource Usage view with the columns you want to print (such as Start, Finish, and
    Work) and then print the Resource Usage view.  Just a thought.  Hope this helps.
    Dale A. Howard [MVP]

  • The specified resource name cannot be found in the image file.

    Dear Experts,
    I have developed an import too and it imports many of the Business Objects from a temporary data base to SAP B1. It was running fine for more than 6 months now.
    Currently when the Tool is importing Credit Notes in to SAP B1, the following error is thrown.
    The specified resource name cannot be found in the image file.
    And I have no Clue about the error. Any one had any experience regarding the above error???
    Thanks in Advance,
    Vasu Natari.

    Hello VAsu,
    Somethimes this unexpected, ununderstandable eroor messages caused by corrupted observer dll.
    Do a clean up (delete %TEMP%SM_OBS_DLL) folder, and see the result ! (i had several issues in the past with some strange messages...)
    Regards
    János

  • ActiveSync Input Form -- To take AD Resource name from Database column

    Hi All,
    My authorative source is a database table called dbTable.
    I am using an input form to provision into Active Directory. The Active Directory resource name is stored in a dbTable column. I first tried to hardcode the name of AD and do the provisioning, it worked. But wen I tried to take the name of the AD from my dbTable column using
    <Field name='waveset.resources'>
    <Comments>Add the AD account user inducted.</Comments>
    <Expansion>
    <block trace='true'>
    <filterdup>
    <appendAll>
    <ref>waveset.resources</ref>
    <list>
    <ref>activeSync.resourceNm</ref>
    </list>
    </appendAll>
    </filterdup>
    </block>
    </Expansion>
    <Disable>
    <block trace='true'>
    <neq>
    <ref>feedOp</ref>
    <s>create</s>
    </neq>
    </block>
    </Disable>
    </Field>
    It didnt work.
    Plz, can anyone tell me how to bring the name of the AD resource in my input form for provisioning into that AD.
    I need help. Plz treat it as urgent coz i can't move further without this being solved.

    Hello, first try to trace the value, using <ref>activeSync.resourceName</ref> should work,
    also read the example in Identity Manager documentation (PDFs) called: "Example: Disabling Accounts through ActiveSync Capable Adapters"
    Regards,
    Edgar Torres

  • How I can saving visa resource name in windows registery and load it again?

    I use visa functions in my program for serial communication , I want to save selected resource name in windows registery and next time that i run my program, i want to read it from registery and assign it to my visa resource name control.
    example:         My visa resource name control value = COM2
                            I close my program with this value (how i can easily save COM2 to windows registry key ?)
                            I open my program again (how i can load COM2 in my resource name control from registry Key?)
                            How i can access to visa resource name list? example: COM1     COM2      LPT1     COM56     COM255
    Thanks.
    Solved!
    Go to Solution.

    I guess I don't understand your problem. All you have to do is ready the key containing the desired resource name and wire the resulting value to the appropriate terminal on the open VI. That's as hard as it gets...
    Mike...
    Certified Professional Instructor
    Certified LabVIEW Architect
    LabVIEW Champion
    "... after all, He's not a tame lion..."
    Be thinking ahead and mark your dance card for NI Week 2015 now: TS 6139 - Object Oriented First Steps

  • How use USB with VISA resource name?

    Hi, 
    I'm new at LabVIEW and I'm working on a code that has to acquire data from a measurement device.This device only has a USB output so I have to work with it. As far as know the block that is used to refer a external port is VISA resource name. I have installed a driver that recognizes the serial ports, and they appear in the list of VISA resource file at front panel. So I figured that installing the product's USB driver so the USB's ports would appear. I installed and nothing of USB ports. I don't know it is that simple or working with USB ports is a little bit harder. I've tried a lot of things and nothing worked so here I am.
    PS: I have noticed that the driver's version is 64 bits (my pc is 64 bits)  and my LabVIEW version is 32 bits, so could that be the problem?
    The device by the way is Digital Analyzer WT500, Yokogawa.
    Thank you.
    Solved!
    Go to Solution.

    Victor,
    the suggestion of Instrument Driver is to make more easy using the instrument. 
    Normally, you should install a windows drive from manufacturer (if it isn't installed, the instrument will appear like a pendrive in device manager) and the NI VISA. But for some instruments, the manufacturers have API's that uses NI VISA to communicate with your equipments.
    So check if your instrument appear correctly in device manager (as indicated by Yokogawa). If not, check if Yokogawa has an appropriated driver for this instrument and install it. 
    Is it clear?
    If you prefer, contact NI Brazil Support by website or by phone (11)3149-3149 Ext 3.
    Ricardo Ramos
    Engenheiro de Vendas - Sul
    National Instruments Brasil

  • Visa Resource Name in cluster passed to Network Stream writer causes error 42.

    If I try and pass this "motor data" cluster with an embedded VISA resource name:
    to a Network Stream Writer in this manner:
    Then I get this error from the "Write Single Element to Stream" VI
    If I change the motor data cluster TypDef so that a string control is used instead of the VISA reference, the error disappears and the data passes over the Network Stream without problem.
    Is this expected behavior? 
    I thought that the "data in" (type = "POLY"?) like the one found on the "Write Single Element to Stream" VI was supposed to accept pretty much anything...
    Solved!
    Go to Solution.

    Doug
    I would consider this a bug, as the memory location (more precisely the VISA refnum or session) of a VISA resource means nothing on a potentially remote system. Also I was under the impression that most streaming methods like binary file IO, but also the network streams would use the LabVIEW flattened format for data clusters and for that the VISA resource name would be the only logical choice instead of the underlaying VISA refnum, but I might be wrong in this specific case and the default behaviour for flattening VISA resources might always have been to the VISA refnum.
    Considering that the VISA control can resurect the VISA session from a VISA resource name if it is already opened, flattening to the VISA resource name instead would be more logical, but using a string control in the cluster type definition is a reasonable work around of course.
    Rolf Kalbermatter
    CIT Engineering Netherlands
    a division of Test & Measurement Solutions

  • Dynamic Resource Name in  DataStore

    Hi,
    I have situation like this, i need to generate dynamic filename based on the input date passed. For example i have package with following steps
    1. inputDate - inputParameter to the interface
    2.vFileName - name of the output file generated by the Interface
    3. Interface - business logic interface
    The Target Data Store for interface is GENERIC_FILE_TEST. The output file needs to be changed based on input date.
    May be i could use evaluate variable. Not sure about the right syntax.
    Theoritically the logic would
    be
    if(inputDate=xx)
    vFilename==zzz;
    else
    vFileName=vvcv;
    and then use vFileName in resource name field of Target Data Store.
    Appreciate providing correct syntax/technique.
    Thanks

    Hi,
    let me suggest something....
    1 - at package, receive the parameter in the variable (named inputDate for instance)
    2 - write an sql query that solves what you need, like, in a oracle example: (the variable refers to itself)
    select case when #inputDate=xx
    then zzz
    else vvcv
    end
    from dual
    3 - after the step 1 at package, just add the variable again in refresh mode
    4 - execute the interface.
    Make any sense?
    Cezar Santos
    http://odiexperts.com

  • File - Resource name mask

    Hi ODI gurus!
    Today I have a question about resource name (case of file name) mask. Is it possible to add a sthg like * character to resource name? I have a file which incudes a generation date in name. I'd like to load this file but I dont know the full name. Is is possible to create file mask which includes only the "core" file name without date? ie. FILE_YYYYMMDD.csv => FILE_*.csv.
    If its possible please let me know how :)
    Regards,
    PsmakR

    Hi,
    One approach would be use the OdiFileMove tool to rename the file to a fixed filename based on wildcards, then your filename would always be the same when you try to read it in.
    Cheers
    John
    http://john-goodwin.blogspot.com/

  • IDM : How to get the Resource name in Exclude Rule during Reconciliation?

    Hi
    Problem Statement => How to get the Resource name in Exclude Rule during Reconciliation.
    Problem Description => Apparently, we use exclude rule for not consider some account during reconciliation.
    I need the resource name in exculde rule during reconciliation. I tried with getResources() method which is an inbuilt method.But it gives all the resources are aviablable in the repository (IDM). I need only the current reconcilied resource name instead of fetching all the resouce.
    Can any one please help how to get the resource name in exclude rule during reconciliation?
    Thanks in advance for you help.
    Thanks,
    Chellappan

    Hi,
    Thanks for your reply.
    I have 50 resouces and these resouces using the same kind of exclude rules. In the exclude rule, i am using resource name to do some work. If i get the resouce name in exclude rule, then i can use the same exculde rule for 50 resources. This will minimise the rule count from 50 to 1. For that, i need resouce name.
    Thanks,
    Chellappan Sampath.

Maybe you are looking for

  • How to create a matrix like report with description column

    Hi, currently i have two tables - one describing a job and another describing the stock. it is a simple relation where a job uses stock. i join job and stock using stock_code. there are three categories of stock - namely envelope, insert, stationary.

  • My Book appears greyed out in the Books section

    A purchased book, sometime back in September but I seem to have deleted the receipt e-mail, is now "greyed out" and seems to be a corrupted file. Can I recover somehow? I tried going into Purchased but it doesn't show there but I am sure I did purcha

  • COPA to special ledger

    Hi, I need to know if it is possible to transfer copa data to a special ledger if I have account based copa. Thank you very much

  • Why do we use java.io.serializable

    i was studing javabeans. i found out we implements java.io.serializable. can anyone explain why do we use it? S

  • Problems with linking to private content?

    Soon after we moved our publically-accessible content into the Public Site Manager, the links to our private content stopped working. Even repeating the "Copy Link" in iTunes does not result in a link that works. I've already posted about our as of y