ChnPropSet from GPI-Dll

Hey!
I think this would have been asked before, but I could not find the answer.. so..
I am creating a Waveform-Channel from a GPI-dll. Transferring the data works fine, but now I am stuck at the offset and increment parameters which I cannot set. Following some examples here, I have created the following code:
#import "DIAdem.tlb" no_namespace
::CoInitialize(NULL);
ITOCommandPtr pITOCommandT;
pITOCommandT.CreateInstance("DIAdem.ToCommand");
pITOCommandT->CmdExecuteSync(_variant_t("Call ChnPropSet(10, \"wf_start_offset\", 1.734)"));
::CoUninitialize();
Actually, the 10 as a channel number is hardcoded here, in the program, I am getting it when creating the channel, via
hDataObjTData = hDataObjChannelGet( szDataObjNameT,f_size_,1,1);
int chn = hDataObjTData;
And then chn contains the channel number. Don't know if that is the way to go, but it's the only solution I have found quickly..
Anyhow, the CmdExecuteSync-call always fails. I have tried it with call, without call, " and ' as quotation marks, and also with and without brackets.
What have I missed, how does it work?
Many thx!!

Actually, after trying this
//pITOCommandT->CmdExecuteSync(_variant_t("Call ChnPropSet(10, \"wf_start_offset\", 1.734)"));
//pITOCommandT->CmdExecuteSync(_variant_t("Call ChnPropSet 10, \"wf_start_offset\", 1.734"));
//pITOCommandT->CmdExecuteSync(_variant_t("ChnPropSet(10, \"wf_start_offset\", 1.734)"));
//pITOCommandT->CmdExecuteSync(_variant_t("ChnPropSet 10, \"wf_start_offset\", 1.734"));
//pITOCommandT->CmdExecuteSync(_variant_t("ChnPropSet 10 \"wf_start_offset\" 1.734"));
//pITOCommandT->CmdExecuteSync(_variant_t("ChnPropSet 10 'wf_start_offset' 1.734"));
//pITOCommandT->CmdExecuteSync(_variant_t("ChnPropSet(10, \"wf_start_offset\", 2)"));
//pITOCommandT->CmdExecuteSync(_variant_t("Call ChnPropSet(10, \"wf_start_offset\", \"1.734\")"));
//pITOCommandT->CmdExecuteSync(_variant_t("Call ChnPropSet 10, \"wf_start_offset\", \"1.734\""));
//pITOCommandT->CmdExecuteSync(_variant_t("ChnPropSet(10, \"wf_start_offset\", \"1.734\")")); // <- good
//pITOCommandT->CmdExecuteSync(_variant_t("ChnPropSet 10, \"wf_start_offset\", \"1.734\"")); // <- good
//pITOCommandT->CmdExecuteSync(_variant_t("ChnPropSet 10 \"wf_start_offset\" \"1.734\""));
//pITOCommandT->CmdExecuteSync(_variant_t("ChnPropSet 10 'wf_start_offset' '1.734'"));
I found out that the last parameter also needs quotation marks. Did I miss this in the documentation??
I already have a new problem though: how can I tell DIAdem that this is a waveform channel?
This one, it does not like:
_snprintf(temp, sizeof(temp), "ChnPropSet %i, \"waveform\", \"Yes\"", chn);
pITOCommandT->CmdExecuteSync(_variant_t(temp));
, just like these lines of code
// wf_samples
_snprintf(temp, sizeof(temp), "ChnPropSet %i, \"wf_samples\", \"%i\"", chn, length);
pITOCommandT->CmdExecuteSync(_variant_t(temp));
// wf_time_pref
_snprintf(temp, sizeof(temp), "ChnPropSet %i, \"wf_time_pref\", \"relative\"", chn);
So, again, I don't know what to do..
Any ideas?

Similar Messages

  • How to save tdm file from GPI extension DLL

    Hi,
    Is there any way to save data channels to tdm file format from GPI extension dll.
    I've tried lDataSave function, but I get DAT file format.
    I've also tried using Diadem.TOCommand interface, It'works with CmdExecuteASync method, but not with CmdExecuteSync (I've thought using a new thread with CmdExecuteASync, but what about synchronization ?).
    As I need to run a process like, do something, save tdm file, then do another thing, I'm a little lost.
    Thanks for any suggestion.
    JMA.

    Hello!
    First: I have no solution!
    Second: Some remarks to using a OLE interface to DIAdem in GPI.
    My experience is that there are only few situations and circumstances where it might be the only way to solve a problem. There are some critical things to know. If you create a ToCommand interface it isn't guaranteed that you get an interface to the proccess you are running in. In normal cases it will be but you can't be sure! CmdExecuteSync doesn't work because usually your command is initiated out of a script. While running a script DIAdem will not execute another command.
    The problem with CmdExecuteASync is that the command will be put onto the DIAdem command stack. It will be executed after the script is finished. You can not be sure that the channel data is the same as it was at the time you called CmdExecuteASync. Multiple Calls to CmdExecuteASync will be executed after another.
    Sorry that I do not have a solution but perhaps I can avoid some frustrating DIAdem-OLE-Test-Sessions.
    Matthias
    Matthias Alleweldt
    Project Engineer / Projektingenieur
    Twigeater?  

  • GPI dll for C code functions

    Hi,
    I'm trying to make a call C code functions inside DIAdem, I've been investigating and so far the best option seems to be the GPI .dll registration. Later on I installed all the GPI ToolKit 11.0, but most of the features in the example are not working in DIAdem 2012 SP1, also I tried to work with the GPI wizard but then i found out later that only can be executed in Visual C++ 6, (software that I can't access).
    So I was wondering if exists a relative easy way to make the call of the functions inside DIAdem. Or even recieved some help with GPI tool, since I barely understand it and most probably I'm missing something.
    Thank you in advance.

    Hi Naoa,
    I believe I've heard that there will be a GPI api compatible with DIAdem 2012 SP1, but I do not know when-- hopefully Walter Rick will comment on that.  Another option would be to add a COM wrapper around your C code and call it straight from a DIAdem VBScript.  Another option would be to use the LVRuntime object in a DIAdem VBScript to call a LabVIEW VI that wraps the C code.
    Are you wanting to make use of a static library of C functions or a DLL written in C?
    Brad Turpin
    DIAdem Prodeuct Support Engineer
    National Instruments

  • Calling a function from a DLL, exectution in background mode.

    Dear Experts,
    We have created an ABAP report the calls a function from a DLL file. If the report is executed in on-line mode the program calls and executes the function from the DLL, but if the ABAP programa is executed in background mode it doesnt calls the DLL function.
    Do you know a way to solve the problem when executing in background mode?
    Best regards.
    Antonio

    Hi Gabriel,
    Let me explain in details about my DLL function.
    We are importing the business partners from legacy system into the SAP CRM system, so at the moment we created the BP master data via BAPI, I get the name of the BP and this moment I call the function in the DLL file. I export the parameter name and I receive back a simplified string with the name reduced to a code. This code I get back from the dll it is insert in a Z table, so there is no interaction in the screen, all must be executed in background mode, because there are a lot of business partners to be converted in SAP system.
    I am sending my code for your considerations.
    Instancia a DLL
      CREATE OBJECT dll 'MTCODE.CPFONET'.
      IF sy-subrc NE 0.
        RAISE without_dll.
      ENDIF.
    Move para a tabela interna IT_NAME os valores recebidos na TI_NAME
      it_name[] = ti_name[].
    Para cada registro importado
      LOOP AT it_name.
        CLEAR v_string_ret.
        wa_matchcode-zregid     = it_name-zregid.
        wa_matchcode-name1_text = it_name-name1_text.
        v_string = it_name-name1_text.
        CONDENSE  v_string.
        TRANSLATE v_string TO UPPER CASE.
        CALL METHOD  OF dll 'SetNome' EXPORTING #1 = v_string.
        CALL METHOD  OF dll 'ExecMatch'.
        CALL METHOD  OF DLL 'GetMCData' = v_string_ret.
        FREE OBJECT dll.
      Preenche os campos do match-code de acordo com o retorno da DLL
        SPLIT v_string_ret
        AT '|'
        INTO wa_matchcode-zparmcln
             wa_matchcode-zparmcfn
             v_empty
             wa_matchcode-name_first
             wa_matchcode-name_last
             wa_matchcode-namemiddle.
      Adiciona o registro com o match-code correspondente na TE_MATCHCODE
        APPEND wa_matchcode TO te_matchcode.
      ENDLOOP.

  • How can I get an unsigned char string with nulls from a dll into LabVIEW 6i?

    The following ethernet packet data is contained in an unsigned char * string returned from my dll (it's formatted on printing):
    Received A 230 Packet On Adapter 0x008F0070
    Ethernet Dest: 01.E0.BB.00.00.15 Src: 00.E0.BB.00.DD.CC Type: 0x8868
    000000: 01 E0 BB 00 00 15 00 E0 : BB 00 DD CC 88 68 48 41 .............hHA
    000010: 00 E0 BB 00 DD CC 80 B3 : 00 00 FF FF 00 02 00 01 ................
    000020: 01 00 F0 18 FF 7F 7F FF : FF 7F 7F FF FF 7F 7F FF ................etc., etc.
    However, when I read this string into LabVIEW 6i, I only get the following:
    01E0 BB
    Which is the data before the first NULL or 00 information. I found a "Remove Unprintable Chars.vi" but it
    just sees more data before the above string, nothing after, as seen here: 5C30 31E0 BB.
    Anybody have any suggestions for how to get the rest of the string? Is there something I can do to further reformat my dll? The dll I'm using is already a wrapper around another dll so I have some flexibility, but the bottom line is, the data I want is in the format of an unsigned char *.

    Excellent advice, this mostly works so I have some further questions:
    I am just reading network traffic off my ethernet card right now, but here is what I get using my C program to test:
    000000: 01 E0 BB 00 00 15 00 E0 : BB 00 DD CC 88 68 48 41 .............hHA
    000010: 00 E0 BB 00 DD CC 80 B3 : 00 00 FF FF 00 02 00 01 ................
    000020: 01 00 38 3C FF 7F 7F 7F : 7F 7F 7F FF FF 7F 7F FF ..8<............
    000030: FF 7F 7F FF FF 7F 7F FF : 7F 7F 7F FF FF FF FF FE ................
    000040: FE FF FF FF FF 7F 7F 7F : 7F 7E 7E 7F 7F 7E 7E FF .........~~..~~.
    000050: 7F 7F 7F 7F FF 7F 7F 7F : 7F 7F 7F FF FF 7F 7E 7F ..............~.
    000060: 7F 7F 7E 7F 7F 7E 7F FF : FF 7F FF FF FE FF FF FE ..~..~..........
    000070: FF FF FF FF FF 7F 7F FF : FF 7F 7F FF FF FF FF FF ................
    000080: FF 7F 7F FF FF 7F 7F FF : FF 7F 7F FF FF 7F 7F FF ................
    000090: FF 7F 7F 7F FF 7F 7F 7F : 7F 7F 7F FF FF 7F 7F FF ................
    0000A0: FF 7F 7F 7F 7F 7E 7E 7F : 7F 7F FF FF FF FF FF FF .....~~.........
    0000B0: FF FF 7F FF FF 7F 7F FF : 7F 7F 7F FF FF 7E 7F FF .............~..
    0000C0: FF FF 7F FF FF 7F 7F FF : 7F 7F 7F FF FF 7F 7F FF ................
    0000D0: FF 7F 7F FF FF 7F 7F 7F : 7F 7F 7F FF FF FF FF FE ................
    0000E0: FE FF FF FF 00 01 : ................
    And here is what I get using LabVIEW to call the dll:
    0015 00E0 BB00 DDCC 8868 4841 00E0 BB00 DDCC 80B3 0000 FFFF 0002 0001 0100 9600 7F7F 7F7E 7F7F 7F7F 7F7F 7F7F 7F7F 7F00 B405 4300 3300 0000 0000 0000 01E0 BB00 0015 00E0 BB00 DDCC 8868 4841 00E0 BB00 DDCC 80B3 0000 FFFF 0002 0001 0100 9600 7F7F 7F7E 7F7F 7F7F 7F7F 7F7F 7F7F 7F00 F405 1B04 0C04 0000 0000 0000 8000 0000 0000 0000 0800 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000
    The first thing I notice is that the first 4 bytes are chopped off, and after about 50 bytes, the data is corrupted until the sequence starts to repeat, but this time it starts with the missing 4 bytes and still corrupts after about 55 bytes.
    I am expecting the data in LabVIEW to look very similar to the C data because the network packets I am grabbing are pretty consistant, only a couple bytes will vary between them, not the number I am seeing in LabVIEW.
    Another side effect I'm seeing is that I can only run my labVIEW code once, if I try running it again it crashes with failures such as:
    memory could not be "read"
    For reference, I am opening and closing the network adapter inside the read function of my dll, but the pointer seems like it should be intact...
    Attachments:
    zListAdapters.vi ‏30 KB
    listAdapters.dll ‏201 KB
    Reading.dll ‏213 KB

  • How to auto-recognize the function parameters called from a DLL built by VC6.0

    Hi,
    I use Teststand 3.5 with C/C++ Adapter, and the DLL is built by VC6.0.
    While I specify module for an action, the parameters of a function called from the DLL are not recognized.
    Since I have the DLL source, I know I can select the source file and verify prototype in the "Source Code" Tab.
    Under the way, almost parameters can be recognized, but some parameters, e.g. HANDLE or I definded, can not ( shows error message "The function definition cannot be found in the source file...").
    How to recognise these parameters?
    Thanks.

    The problem isn't that TestStand doesn't have enough native types. A handle can be represented in a TestStand numeric variable just fine. Instead, the issue is that when you select Verify Prototype, TestStand doesn't fully pre process your headers and compile your code to determine the types. To do so would require TestStand not only to be a full C/C++ compiler but it would also have to be able to read your compiler's projects and settings to resolve include paths, macros, etc.
    Since TestStand is not a C/C++ compiler, it just looks for the standard basic data types plus a few more that are common in test code.  Other data types will not be automatically recognized even if they can be mapped to TestStand types.
    Another option it to create a type library for your dll so that TestStand can automatically read the data type information from it. However, I don't know if that works for struct parameters and I looked for the document on devzone that explains how to do that in VC++ and it has been moved or deleted
    Maybe an AE would know of a link to a current document that describes how to do this?

  • Can I call a function from a dll in LabVIEW that returns:double*string and int.?

    I have a function from a dll that return a double* string and an integer. How can I call this function from LabVIEW? There is a possibility to work in LabVIEW with a double* string?

    pcbv wrote:
    > Hello all,<br><br>The header of the function is:
    >
    > "HRESULT WRAPIEnumerateDevices(WRAPI_NDIS_DEVICE **ppDeviceList, long *plItems);"
    >
    > where WRAPI_NDIS_DEVICE have this form:
    >
    > typedef struct WRAPI_NDIS_DEVICE<br>{<br>
    > WCHAR *pDeviceName;<br>
    > WCHAR *pDeviceDescription;<br><br>}
    > WRAPI_NDIS_DEVICE;<br><br>
    >
    > The function is from WRAPI.dll, used for communication with wireless card.
    > For my application I need to call in LabVIEW this function.
    Two difficulties I can see with this.
    First the application seems to allocate the array of references
    internally and return a pointer to that array. In that case there must
    be another function which then deallocates that array again.
    Then you would need to setup the function call to have a pointer to an
    int32 number for the deviceList parameter and another pointer to int32
    one for the plItems parameter.
    Then create another function in your DLL similar to this:
    HRESULT WRAPIEnumExtractDevice(WRAPI_NDIS_DEVICE *lpDeviceList, long i,
    CHAR lpszDeviceName, LONG lenDeviceName,
    CHAR lpszDeviceDesc, LONG lenDeviceDesc)
    if (!lpDeviceList)
    return ERROR_INV_PARAMETER;
    if (lpDeviceList[i].pDeviceName)
    WideCharToMultiByte(CP_ACP, 0,
    pDeviceList[i].pDeviceName, -1,
    lpszDeviceName, lenDeviceName,
    NULL, NULL);
    if (lpDeviceList[i].pDeviceName)
    WideCharToMultiByte(CP_ACP, 0,
    pDeviceList[i].pDeviceDescription, -1,
    lpszDeviceDesc, lenDeviceDesc,
    NULL, NULL);
    return NO_ERROR;
    Pass the int32 you got from the first parameter of the previous call as
    a simple int32 passed by value to this function (and make sure you don't
    call this function with a higher index than (plItems - 1) returned from
    the first function.
    Rolf Kalbermatter
    Rolf Kalbermatter
    CIT Engineering Netherlands
    a division of Test & Measurement Solutions

  • Error from libf4f.dll: C.

    We are trying to stream HTTP live streaming with the live packager and flash access. We have followed the steps on the site for both the streaming and setting up the tomcat servers. Everything works fine until we are pushing to the FMS and get following error message in the log file core.00.log
    #Version: 1.0
    #Start-Date: 2011-02-22 16:47:11
    #Software: Adobe Flash Media Server 4.0.0 r1121 x64
    #Date: 2011-02-22
    #Fields: date   time                    x-pid                   x-status             x-ctx                   x-comment
    2011-02-22       16:47:11            6796                    (i)2581237        Starting admin app on core (6796).                  -
    2011-02-22       16:47:11            6796                    (i)2631174        Listener started ( _defaultRoot_ ) : 192.168.42.34:19351 (rtmfp-core)/v4            -
    2011-02-22       16:47:11            6796                    (i)2631174        Listener started ( _defaultRoot_ ) : 127.0.0.1:19351 (rtmfp-core)/v4            -
    2011-02-22       16:47:11            6796                    (i)2631509        Public rtmfp-core addresses for listener _defaultRoot_ are: 192.168.42.34:19351;127.0.0.1:19351              -
    2011-02-22       16:47:11            6796                    (i)2581246        Core (6796) sending register cmd to edge.  -
    2011-02-22       16:48:03            6796                    (e)2611178       Error from libf4f.dll: C.             -
    2011-02-22       16:48:03            6796                    (e)2611423       Failed to record livestream2 (Unknown Error).                       -
    2011-02-22       16:48:03            6796                    (e)2611178       Error from libf4f.dll: C.             -
    2011-02-22       16:48:03            6796                    (e)2611423       Failed to record livestream3 (Unknown Error).                       -
    2011-02-22       16:48:03            6796                    (e)2611178       Error from libf4f.dll: C.             -
    2011-02-22       16:48:03            6796                    (e)2611423       Failed to record livestream1 (Unknown Error).                       -
    We have tried on two different FMS on two different machines. We still get the same error
    It works fine when we just stream HTTP live without flash access.
    It is really hard for us to debug when we only get “unknown error”
    Thanks
    Samuel Oest

    Hi Samuel,
    I've submitted a customer-reported bug regarding this issue.  Our Technical Support Staff will be contacting you soon.
    cheers,
    /Eric.

  • How can i pass string from C++ DLL to Java via JNI?

    Hi everybody. I made a DLL with Borland C++. I must pass a string from this dll to Java via JNI.Namely i define a string variable in C++ DLL and i send this variable's value to Java via JNI.
    I can pass integers but i couldnt Strings. . How can i do this? is there any sample?

    Hi,
    So your function should be private static native String get_text();
    (It's often a good idea to make native methods private since when you change signatures you generally have to change java wrapper methods only).
    I know nothing about C++ strings but I'm pretty sure that you can convert it to char*, so
    do :
    char* szMyString = myString.toChar*();
    Then return from native with JNU_NewStringPlatform(env, szMyString)
    (see my 1st answer for JNU_NewStringPlatform() description).
    --Marc (http://jnative.sf.net)                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   

  • Call function in LabView from a DLL, then access global variable from DLL

    I have created a DLL in LabWindows with a function and a structure.  I want to call the function from within LabView and then access the global structure.  I am able to call the function from the DLL with a "Call Library Function Node" and can access the return value, but I cannot figure out how to access the global structure.  The structure is declared in the DLL header file with __declspec(dllimport) struct parameters.
    Is there any way of accessing this structure without using the Network Variable Library?
    Solved!
    Go to Solution.

    dblok wrote:
    When you say "access to" or "the address of" the global variable, do you mean to pass the variable as an argument to the function call in the DLL?  If so, then I was not really sure how to pass a cluster from LabView by using the "Call Library Function Node".
    Yes, that's exactly right.  I would include a pair of helper functions in the DLL to read and write the global variable.  Alternatively you might write separate helper functions for each field inside the global structure, depending on the number of fields and whether you want to do any validation on the values.
    You can pass a cluster by reference to a function that expects a struct by setting the parameter to Adapt to Type, so long as the cluster does not contain any variable-length elements (strings or arrays).  The cluster needs to match the struct exactly, and sometimes that involves adding extra padding bytes to make the alignment work.  Variable-length elements in LabVIEW need to be converted to clusters containing the same number of elements as the struct definition (for example, if your struct contains char name[12], you would create a cluster of 8 U8 values, and you could use String to Array of Bytes followed by Array to Cluster to convert a LabVIEW string into that format).  If the struct contains pointers it gets more complicated, and it may be easier to write functions in the DLL to access those specific elements individually.
    If you can't get this working or need help, post your code and an explanation of the error or problem you're seeing.
    EDIT: it is also possible to include a single function in the DLL that returns the address of the global variable, which LabVIEW can then use to access and modify the data, but that's more complicated and likely to lead to crashes if you don't get the memory addressing exactly right.

  • Call multiple functions from same dll with call library function

    hi,
    i am working on a project in wich we need to make a UI to read out a sensor network.
    the UI should be usable in any project, but every node needs a different piece of code depending on the type of sensor with wich it is equipt.
    so i need to be able to call different pieces of code when i need them, and still be able to use the UI in future projects with possibly new types of node we now don't have.
    so someone told me to use DLL's, cause then i would be able to call the code i need the moment i need it.
    but i have never worked with DLL's (just learned about this option 3 day's ago) so i have a question.
    i know i can dynamicly change the DLL i call with the call library function, but can i dynamicly change the function i call from that DLL ?
    or do i have to put a new call library function for each function i want to call, even if its from the same DLL ?
    kind regards,
    stijn

    nazarim wrote:
    ok so there is no (easy and ubderstandable) way for me to dynamicly change wich function i want to call from a certain DLL.
    but now i started wondering, the path on the call library function is not ment to dynamicly change a DLL
    but it does work so, if i am carefull, can i use it for that purpose or will labview give me a series of problems once i start using it in larger programs ?
    Thepath on the Call Library Node can be used to load a different DLL. Obviously since you can't change the function name your other DLL would have to export exactly the same function name and of course with the same parameters. This is seldom the case so it is not the main use of the path input to the Call Library Node. It's main use is as indicated to load DLLs at runtime rather than at load time of a VI. So that an application can run even when the DLL is missing, until the moment the functionality from that DLL is needed.
    If you can make sure that all your DLLs export the same function name with the same parameter you can use the Call Library Node to call into different DLLs through the path input. If however you would need to call different function names you would have to resolve to some DLL which does do the dispatching and invocation using LoadLibrary() and GetProcAddress(). But unless you need to go with DLLs for some reason using the Call By Reference Node can give you an even more flexible approach. 
    Rolf Kalbermatter
    CIT Engineering Netherlands
    a division of Test & Measurement Solutions

  • Calling a function from a dll written by using visual studio c++

    Hi, how can i call a function from a dll which is written by visual studio c++ in test stand?  Although the functions in dll are exported and i've chosen c/c++ adapter, i saw no function in test stand. Is there a different step while i'm calling a function from a dll written by c++ than calling a function from a dll written by cvi?

    Hey Sadik,
    Selecting the C/C++ DLL Adapter Module should be sufficient for this. When you drag an action step for this onto the Main Step and navigate to the location of the DLL, the function list should populate and you should be able to select the function you want to use. If this is not the case, would you be able to post this DLL so that we can test this on our end?
    Regards,
    Jackie
    DAQ Product Marketing Engineer
    National Instruments

  • Recupérer les valeur d'un Control via un .obj appelé depuis une DLL- Getting a Control value from an .obj file called from a dll

    Bonjour,
    Suite au passage à la version CVI 2013, il faut passer par un fichier .obj au lieu du .c quand on veut utiiser la LoadExternalModule.
    Le pb qui en résulte impossibilité de récupérer la valeur des control dans l'uir géré par le .obj qui est appelé par une dll.
    Autrement, il m'est impossible de faire parvenir à la dll les valeur des control ( dll qui appelle le .obj).
    Quelqu'un a eu le même soucis amigos?
    Merci
    Hi,
    When using the LoadExternalModule function in CVI 2013, we can no longer use a .c file. Instead we have to use an .obj file.
    My issue is that' impossible for me to get a control value from an .iur managed by the .obj witchi is called by a dll. 
    Otherwise it's impossible for me to get the control vale when calling the .obj from a dll.
    Any suggestions Amigos
    Thanks

    For people who could be interested in, here the code I provided to the customer. This code demonstrates that calling a function defined in a .obj file from a DLL which is called itself by a program can be realized without throwing any error.
    In order to use this example, you will have to :
    1) Open "main.cws"
    2) Define "Madll" as Active Project (right clic on the project and click on "Set Active Project")
    3) Build the DLL (CTRL+M)
    4) Define "Main" as Active Project
    5) Click on "Debug Project" in order to build the executable and run it
    This example has been built with CVI 2013.
    Jérémy C.
    National Instruments France
    #adMrkt{text-align: center;font-size:11px; font-weight: bold;} #adMrkt a {text-decoration: none;} #adMrkt a:hover{font-size: 9px;} #adMrkt a span{display: none;} #adMrkt a:hover span{display: block;}
    Travaux Pratiques d'initiation à LabVIEW et à la mesure
    Du 2 au 23 octobre, partout en France
    Attachments:
    main.zip ‏70 KB

  • CR XI R1: viewer can't open report with UFL from COM dll

    Hello all!
    I faced the following problem: report which is uses functions from COM dll doesn't works on customer's pc. CRViewer throws exception when calling ViewReport() method. GetLastError() gives just 0 ...
    All other reports without functions from COM DLL are working on that PC however. Moreover, reports which uses function from non-COM DLL are also working.
    Versions & environment:
    - Report file is designed in CR11, CR Developer; Product type: Full, Product Version: 11.0.0.895
    - Runtime files on customers pc installed by .msi created from merge modules for Crystal Reports XI RDC Deployments (latest available SP4 for CR XI R1: [crxi_rdc_merge_modules.zip|http://resources.businessobjects.com/support/communityCS/FilesAndUpdates/crXI_rdc_merge_modules.zip], as listed on [this|http://resources.businessobjects.com/support/additional_downloads/runtime.asp] page)
    - target OS: WindowsXP SP3, all updates are installed
    - i'm using COM crviewer, but there are some points in application where report is opened using CRPE api - it is also crashing on reports with custom functions from COM DLL
    - UFL DLL is registered and loaded correctly (investigated by debug output), looks like crash occured during attemt to call function
    - just for test I tried to install CR Developer on customers PC: it successfully opens all "problem" reports, but the viewer in application still crashing ...
    I would appreciate any tips / suggestions. Please also let me know if I need to specify versions of other products / components.
    Thx,
    Andrew

    Sorry, but you have to define "viewer just crashed". To different people this means different things; error, viewer never shows up, application terminates, etc., etc., etc....
    If the issue is only 10% of computers then it is not
    Re. "...could be caused by:"
    - previous installation of CR8.5 (or earlier) runtime (how to cleanup it correctly?)
    possibly - see below
    - OS configuration (what we need to ajust?)
    probably not - as long as it's the same OS and SPs
    - something missing in our code (but why it works in 90% cases?)
    -no
    - something wrong with CRXI runtime (but we a using latest available MSMs, and again, this works in 90% ...)
    possibly see below.
    I would approach the issue by running [Modules|https://smpdl.sap-ag.de/~sapidp/012002523100006252802008E/modules.zip] and comparing the dlls loading on a computer that works and one that "crashes"...
    Your second utility is [Process Monitor|http://technet.microsoft.com/en-ca/sysinternals/bb896645.aspx] but ProcMon creates large and difficult to read files.
    Oh, and get the powers that be to start to consider moving away from this legacy "stuff". Like I said, PE APIs have been gone since version 9 of CR and RDC has been retired in CR XI R2 (11.5). Neither product is supported anymore.
    - Ludek

  • Can labview globals or controls be modified directly from a dll

    Is it possible to obtain a pointer or handle to LabVIEW global variables - specifically clusters of scalars, not including strings or arrays, which presumably would occupy a fixed memory area.
    If this is not possible, can the value of data held in LabVIEW controls be modified from a dll by passing control references to the dll and if so how can this be done?
    Using LabVIEW 6i, Windows NT SP6, MS-VisualC++ 6.0

    I created a dll with LabVIEW 6.0 which had as its only input parameter a control refnum for a string control. I used this refnum to modify the value of the string control. I built the dll and then from a new VI called the dll using a call library function, passed it a refnum to a string control in the calling VI and ran it. The value of the string control in the main VI was change by the dll by only passing it a refnum.
    To do this you must have LabVIEW 6.0 Pro or App builder. (I did all this with LabVIEW 6.0.2 update installed)
    Attachments:
    caller.vi ‏8 KB
    chngstring.dll ‏17 KB

Maybe you are looking for

  • I spilt milk on MacBook Pro, it won't start - what can I do? (I've left it alone for awhile)

    A small amount of milk spilt on the top of my MacBook Pro (I bought it new about three months ago). It almost immediately shut off and it refuses to start, even having left it for 30 hours in an attempt to allow it to dry out. My question really is w

  • Adding fields to ALV output list in Tcode S_ALR_87012357

    Hi, I need your help to insert new fields in output at standard t-code S_ALR_87012357 for GST Report. Report name is RFUMSV00. The add/insert columns are 1)Vendor Description, 2)SGD Gross Amt(100% tax Reporting  curr) 3)SGD Tax Base Amt(100% Tax Repo

  • InDesign occasionally crashing when closing document

    We have a plug-in which automatically processes documents, in this case opens, prints, and closes. Occasionally InDesign crashes while performing these actions. From the information I have through our own logs and the crash dump it appears to crash w

  • Is it possible to move items into Family calendar?

    Is there a way to move the items I have in my Calendar into the new Family Calendar?

  • Extending the Thread class

    i would like to do that 1) One thread displays "ABC" every 2 second; 2) The other thread displays DEF every 5 seconds; i need to create the threads by extending the Thread class ... thank you for your help ,             public class Thread1 extends T