Calling function wsastartup() of wsock32 DLL

Could someone tell me how to use the function "wsastartup()" of wsock32.dll to initial a network connection?
Here is the definition of the wsastartup() function:
int WSAStartup(
__in WORD wVersionRequested,
__out LPWSADATA lpWSAData
Parameters
wVersionRequested [in]
The highest version of Windows Sockets specification that the caller can use.
The high-order byte specifies the minor version number; the low-order byte specifies the major version number.
lpWSAData[out]
A pointer to the WSADATA data structure that is to receive details of the Windows Sockets implementation.
Return Value
If successful, the WSAStartup function returns zero. Otherwise, it returns one of the error codes listed below.
For more wsastartup() detail, please visiti
http://msdn.microsoft.com/en-us/library/ms742213%28VS.85%29.aspx
I've tried many times and that cause labview to crash.
Please give an example, thanks.
Devin

smercurio_fc wrote:
The LabVIEW network functions don't operate at that low of a level. Based on what you are looking to get, it seems to me that a third-party software solution would be far easier to use than to try to call Windows API functions from LabVIEW. Have you tried Google to find such software?
I would say it depends what network throughput numbers the OP wants to calculate. If sending out data through TCP/IP to some remote location and calculating the maximum or average possible throughput from that it could certainly be done in native LabVIEW. One thing to watch out here is that LabVIEW uses the network socket API in a specific way that is for instance not suited for high througput server applications. So the numbers calculated in such a way would be meaningful in comparison with each other but not necessarely a good indication what a high througput server application could achieve using overlapped and/or I/O Completion Ports Winsock calls.
If it is about generic data about the winsock usage then there are IPHLP.DLL APIs to get at some of that data and some is available through the registry in the Performance data section.
Rolf Kalbermatter
CIT Engineering Netherlands
a division of Test & Measurement Solutions

Similar Messages

  • Simulation model which call functions in an other dll...

    I have a C simulation model that I implement like NI Model Framework template (NI_VStand_Model_Framework_Guide.pdf ). If I use this simple model I can deploy on my PXI. But I must call functions which are in an other dll. When I call functions in other DLL I can't deploy because Veristand specify that the model is not compatible.
    NI VeriStand: The specified compiled model is not compatible with NI VeriStand.
    =========================
    NI VeriStand: NI VeriStand Engine.lvlib:VeriStand Engine Wrapper (RT).vi >> NI VeriStand Engine.lvlib:VeriStand Engine.vi >> NI VeriStand Engine.lvlib:VeriStand Engine State Machine.vi >> Model Execution.lvlib:Initialize Model Loop Data.vi >> SIT Model API.lvlib:Initialize Model.vi >> SIT Model API.lvlib:Load Model DLL.vi
    <append>=========================
    NI VeriStand: Failed to load c:\ni-rt\NIVeriStand\Models\LD1_T1.dll
    If I use DLL Checker there is no bad import.  How to add a simulation model in veristand which call function in an other DLL?

    Thank you for your answer.
    I know how to import a dll in veristand. My Dll  is LD1_T1. I can import it in Veristand without error. But this DLL depends of an other dll (addition.dll) as you can see in the print screen.
    When I try to deploy to my PXI I have an error message of compatibility. 
    NI VeriStand: The specified compiled model is not compatible with NI VeriStand.
    =========================
    NI VeriStand: NI VeriStand Engine.lvlib:VeriStand Engine Wrapper (RT).vi >> NI VeriStand Engine.lvlib:VeriStand Engine.vi >> NI VeriStand Engine.lvlib:VeriStand Engine State Machine.vi >> Model Execution.lvlib:Initialize Model Loop Data.vi >> SIT Model API.lvlib:Initialize Model.vi >> SIT Model API.lvlib:Load Model DLL.vi
    <append>=========================
    NI VeriStand: Failed to load c:\ni-rt\NIVeriStand\Models\LD1_T1.dll
    For LD1_T1.dll I have use NI Model Framework template (NI_VStand_Model_Framework_Guide.pdf ).
    If I check my Dll with dll checker it's ok but I can't deploy. 
    Please somebody have an idee to deploy my model ?

  • Calling function between subprojects and DLL in WINCE7

    We inherit a project develop using Platform Builder with WINCE7 and Visual Studio 2008. The project has a BSP, 5 sub-projects and a DLL. The problem is that when we add a function to the DLL Data Manager and try to call the new function from any of the subproject
    using an Data Manager object that is currently used in the subproject to call other functions on the Data Manager DLL, we get the following error:"Error 107 Configuration_Setting_Mapper.obj : error LNK2019: unresolved external symbol "public: void
    __cdecl Data_Manager::Configuration_Manager::Set_Default_TEST(void)" (?Set_Default_TEST@Configuration_Manager@Data_Manager@@QAAXXZ) referenced in function "public: bool __cdecl Configuration_Setting_Mapper::Set_UserName_Default(void)" (?Set_UserName_Default@Configuration_Setting_Mapper@@QAA_NXZ)
    Same error is received when we try to change the return type of any of the functions in the Data Manager DLL. Do we have to set a link between the Data Manager and the subproject? What could be missing?

    So the import library for the DLL needs to be updated (with the new function which you are exporting). Otherwise, it's as though you installed a new version of desktop Windows with new capabilities but used the old API libraries; your code won't link because
    the API library *you are using* doesn't match the DLL you want to call.
    Since your code compiles, you're obviously using the new header file(s).
    So, what to do? Without seeing the projects and understanding how the original structure was intended to work, I'm not sure we can say. You may be linking with a library in the SDK folder but not regenerating that library when the DLL changes, or you may
    not be generating a new import library when rebuilding the DLL.
    Paul T.

  • Does anyone have an example VI about how to call the animatewindow function in the user32.dll using CLN in Labview?

      I want to call the WinAPI function-animatewindow in user32.dll to produce some special effect when showing or hidding windows, but i don't know how to using this Win API to achieve my purpose?
      Does anyone have an example VI about this application?
      Thanks in advance for your help.

    You have to use the Call Library Function Node to call Windows API functions. The animatewindow function itself has some pretty simple parameters. You first need to get the window handle. There are a set of Windows API Function Utilities (32-bit) for LabVIEW that you can use. In there there is a VI (Get Window Refnum) that gets the window handle. It's a simple call to a Windows API function. You would call the animatewindow function in the same way. In this case there are 3 parameters: the window handle (returned by a FindWindow API call), a DWORD (32-bit integer) for the duration, and another DWORD for the flags.

  • How to pass a pointer in labview library call function by using dll programmed in Labwindows​?

    Hi,
    I'm trying to interface a camera with Labview.  However, the camera can only be programmed by C, so I'm using Labwindow CVI.
    I need to pass a camera handle from one function to another, eg. from a opencamera function to setparameter function.  
    /* Load the Qcam driver and Open the First Camera */
    void DLLEXPORT LoadDriverAndOpenCamera()
    QCam_CamListItem cameraList[10];
    unsigned long cameraListLength=sizeof(cameraList)/sizeof(cameraL​ist[0]);
    //load the driver
    QCam_LoadDriver();
    //get a list of the cameras
    QCam_ListCameras(cameraList,&cameraListLength);
    //listLength is now the number of cameras available
    QCam_Handle hCam;
    //Open the first camera in the list
    QCam_OpenCamera(cameraList[0].cameraId, &hCam);
    Apparently, caemraId is an unsigned long (unsigned 32-bit in Labview 2012 32-bit? ) and QCam_Handle is defined as void*, so it's a pointer that points to an unsigned 32-bit.
    When I only use C for programming, I can pass hCam variable to other functions as long as it's declared as global variable.  Ex, the next function can be void SetParameter(QCam_Handle hCam).  However, here I'm trying to make a dll by Labwindows/CVI and then call LoadDriverAndOpenCamera() function through library call in Labview.  
    My question is:  How can I pass hCam to other functions in the same dll?  Do I have to add paramter to the function? For example:
    void DLLEXPORT LoadDriverAndOpenCamera(unsigned long cameraId, QCam_Handle* cameraHandle)
    And then add two lines:
    cameraId=cameraList[0].cameraId;
    cameraHandle=hCam;
    into the function?  Then I can pass cameraHandle out?  However, hCam will still have void* type.
    Even if that's the case, how can I set up library call node on Labview?  In the arg parameter set up, I don't see pointers?  It seems I cannot set up an output node to be a pointer that points to a unsigned long.
    Thank you very much for your help!
    Best,
    Charles
    Solved!
    Go to Solution.

    Hello Charles, 
    I noticed you posted a similar question here. do you have any further questions about using the call library function node? 
    Haley N
    Applications Engineer
    National Instruments

  • Call function from C++ (dll file) in Flex

    Hi,
    i using Adobe Flash Builder with Flex 4 , i write a C++ Code in dll File , i need to access to my Function in dll file in Flex ?? what should i do ??

    Lets make sure you are performing the correct actions:
    1.  Place a Call Library Function node on your block diagram.
    2.  Double click the node to open up the Call Library Function dialog box.
    3.  Click the Browse button and navigate to the DLL function.  Select the proper DLL and click Open, or just double click on DLL.
    4.  On the Function Name box, click on down arrow.  A list of functions found in the DLL should be displayed.  Choose the function.
    5.  On the Calling Conventions box, click on down arrow and select C or WINAPI.  In your case, it should probably be C.
    6.  The Parameter box should show return type.  In the Type box, select the data type of the return value.  Since you won't see HRESULT here, you need to find out what data type HRESULT is in the C code.  I would guess it is a numeric so select numeric from the drop down list.
    7.  Click the Add a Parameter After button.
    8.  In the Parameter box, change the name arg1 to the actual name of your first parameter, which is byPortNumber.
    9.  In the Type box, choose Numeric, since a BYTE is a numeric in Labview.
    10. In the Data Type box, choose Unsigned 8-bit Integer, since a BYTE is a U8 in Labview.
    11. In the Pass box, choose Value.  If the C parameter was a pointer (*BYTE), you would choose Pointer to Value.
    12. Verify that the contents of the Function Prototype box contains the correct syntax according to the C declaration.
             C:  HRESULT RSPInitComm (BYTE byPortNumber)   should be in Labview: long RSPInitComm(Unsigned char byPortNumber)
    13. Click OK button.
    Try it out.
    If you get a crash, change the Calling Convention to WINAPI.
    - tbob
    Inventor of the WORM Global

  • "Calling functions that are in a class based DLL (MFC extention DLL)"

    "Calling functions that are in a class based DLL (MFC extention DLL)"
    "Calling functions that are in a class based DLL (MFC extention DLL)
    I have a DLL written in VC++ using MFC exteintion DLL.
    The functions are used to extract information from a hardware card.
    eg.:
    class AFX_EXT_CLASS WSDevice : public cAsyncSocket
    This is a class in a DLL. There are a number of functions in this DLL that we need to call from Labview 5.0
    How do we call these functions?
    Normally (in VC++ /C++) we ceate a instance of this class like WSDeviceObj and use the function call :
    WSDeviceObj.fucntion name
    Kindly Help.
    Satish Narayana"

    You can create a wrapper dll from which you can call your dlls functions.
    Guidelines on how to create a dll that can communicate with LabVIEW are provided in the document "Using External Code in LabVIEW", which should be included with LabVIEW. You can download the document also from www.ni.com at:
    http://digital.ni.com/manuals.nsf/web_productcurre​nt/4F1447F7CD83D6D88625690D00637CED?OpenDocument
    Regards;
    Vargas
    www.vartortech.com

  • Call function from "CP210xManufacturing.dll"- Silicon Labs

    I am developing a production line test system that includes retrieving and setting the VID, PID, product string, serial number maximum power consumption of a Silicon Labs CP2102 USB - UART bridge using Labview 8.2.
    Unfortunately I could only call one function { CP210x_GetNumbDevices() }. Wondering any one can help me to call others.
    The Document  : http://www.silabs.com/public/documents/tpub_doc/anote/Microcontrollers/Interface/en/an144.pdf
    CP210xManufacturing.dll :http://www.silabs.com/public/documents/software_doc/othersoftware/Microcontrollers/Interface/en/an14...
    Tuong

    G'day Tuong,
    I'm having issues finding the device i want (VID / PID) on my machine using the "CP210xManufacturing.dl"and calling function "CP210x_GetNumDevices()"...
    Just wondering if you have any details on this....
    Hahaha, I just saw the date you wrote this thread... Hmmm, I might just ask you at work tomoz...
    Cheers
    Tim

  • How can I build an application that calls functions in a dll if the associated hardware is not present?

    I am trying to build an application that use the "Call Library Function" node to call functions in a dll.
    The dll was provided by a third-party and includes functions to drive an I2C communication board.
    The problem I have is that the dll does not not properly because the hardware is not present.
    Therefore when I load the VI a broken arrow is displayed and when I am not able to build the application.
    I will not be running the application on the PC where I build the application, therefore I want to be able to build the application on a remote PC that has not all the hardware installed. Once the application will be build it will be installed on the target PC that has all the hardware.
    How can I make the application builder to build the application event if the dll is not properly loaded? (the dll will be properly loaded on the target PC)
    I want to do this on LabView 5.1.1, any ideas?

    Some .dlls don't try to attach to the driver when loaded.
    I've worked with both and unfortuately, I've not figured out a way around this problem.
    You could possibly use the Conditional Disable structure around the dll calls so they would not be loaded unless you're in the runtime engine. But i've not tried this so I don't know for sure if it's possible.
    Anyone??
    Ed
    Ed Dickens - Certified LabVIEW Architect - DISTek Integration, Inc. - NI Certified Alliance Partner
    Using the Abort button to stop your VI is like using a tree to stop your car. It works, but there may be consequences.

  • Call function RFC in a loop and kill old session

    Hi,
    we have a problem with a program.
    here's a part of the code:
    DO.
        CALL FUNCTION 'YC_REFRESH_GPT_START_CM25' STARTING NEW TASK 'TEST'
          EXPORTING
            i_profile       = p_prfl
            i_werks         = p_werks
            i_arbpl_low     = s_arbpl-low
            i_arbpl_high    = s_arbpl-high
          TABLES                                              
            t_arbpl =  it_arbpl.                                
        PERFORM wait_for_refresh.
        PERFORM terminate_session.
      ENDDO.
    So the program does a call function, waits a while, then terminates the session and recalls the function.
    Apparently, like this the data should be updated.
    But in the terminate session, the session is terminated using:
    CALL 'ThUsrInfo' ID 'OPCODE'  FIELD opcode_delete_mode
                       ID 'MODE'    FIELD l_mode.
    And it works the first time, but the second time there is a dump.
    So, is there another way to achieve what this program is trying to do?
    Or is there another way to kill the session?
    Thanks!!

    Hi,
    the DLL will stay in memory as long as there is a program running which has not closed (unloaded) the DLL.
    Doing repetitive calls to the DLL is irrelevant in this context. LV opens the DLL as soon as needed and will only unload it when there is no VI in memory which has a CLN to that DLL...
    Best regards,
    GerdW
    CLAD, using 2009SP1 + LV2011SP1 + LV2014SP1 on WinXP+Win7+cRIO
    Kudos are welcome

  • Java calling functions in an OCX

    Hey folks,
    I have a proprietary OCX for a clicker system I use in my high school math classroom. The vendor gave me a VB SDK for calling the OCX functions and that works fine. However, I want to write apps using Java. So, I've thought about two options: 1) creating a VB DLL wrapper around the OCX and then calling routines from the VB DLL and 2) calling the routines from Java using some kind of Java COM bridge.
    Choice 1 seems like the more difficult choice because I'll still have to use some kind of Java COM bridge to access the VB DLL. Also, if my memory serves me correctly, I recall that VB DLL's are not necessarily accessed the same way that C or C++ DLL's are (or maybe that changed with .NET?).
    So, I spent the last week trying to find a Java COM bridge to make contact with the OCX directly. I've read through many posts here and I've searched around the net quite a bit. I've looked at JACOB, com4j, jawin, and comeclipse and I still can't get to the point where I can create a Java. com4j and comeclipse have come the closest to making me feel like there is light at the end of the tunnel. com4j's web site suggested using OLEVIEW to create the .IDL file that is almost like having the the type library (.tlb). That seemed to work, I do have a .IDL file. But when I tried to use com4j to create my wrapper files, the ClassFactory class didn't have any methods defined (it should have had some create... methods).
    So, then I tried comeclipse. That actually took the OCX directly and created a number of Java wrapper code files. The answer may actually already be in my hands, but I'm not sure how to instantiate the objects in the wrapper code files. I'm lucky because the OCX file includes a function that produces an About box (sAbout). So, if I can figure out the syntax to call the About box, I should be able to figure out the rest of the syntax.
    It would be awesome if someone had a clue about the syntax required in order to pull that About box up from Java.
    This is the code from what looks like the main (I guess you could call it the root) file. Furtherdown the page, I have the Java code that includes the sAbout reference.
    Filename: ctlPrsX.java (the OCX is called PrsX.ocx)
    * Generated on Sun Sep 14 14:43:08 PDT 2008
    * This class was 100% generated by the SWTtoCOM Type library
    * generator.  Please do not edit this class manually since
    * all changes will be lost on the next generation.
    package prsx;
    import au.com.swz.swttocom.swt.types.TypeUtils;
    import org.eclipse.swt.internal.ole.win32.GUID;
    import org.eclipse.swt.internal.ole.win32.IUnknown;
    import org.eclipse.swt.ole.win32.OleAutomation;
    import prsx.impl.__ctlPrsXListener;
    import prsx.impl._ctlPrsXImpl;
    public class ctlPrsX extends _ctlPrsXImpl {
         public static final GUID CLSID = TypeUtils.IIDFromString("{E08B4F09-B88A-11D3-B5DB-00104BA291B8}");
         private IUnknown objIUnknown;
         private __ctlPrsXListener mf_ctlPrsXListener;
          * Constructs a new ctlPrsX from the specified OleAutomation.
         public ctlPrsX(OleAutomation oleAutomation) {
              super(oleAutomation);
          * Constructs a new ctlPrsX from the specified OleAutomation and IUnknown.
         public ctlPrsX(OleAutomation oleAutomation, IUnknown unknown) {
              super(oleAutomation);
              this.objIUnknown = unknown;
          * Adds the specified listener to the set of Listeners that
          * will be notified when events occur.
          * @param listener the new listener to add.
          * @return true if the set of listeners did not already contain
          *         the specified listener, false otherwise.
         public boolean add__ctlPrsXListener(__ctlPrsX listener) {
              if (mf_ctlPrsXListener == null) {
                   mf_ctlPrsXListener = new __ctlPrsXListener();
                   addEventListener(__ctlPrsX.IID, 1, mf_ctlPrsXListener);
                   addEventListener(__ctlPrsX.IID, 2, mf_ctlPrsXListener);
                   addEventListener(__ctlPrsX.IID, 3, mf_ctlPrsXListener);
                   addEventListener(__ctlPrsX.IID, 4, mf_ctlPrsXListener);
                   addEventListener(__ctlPrsX.IID, 5, mf_ctlPrsXListener);
                   addEventListener(__ctlPrsX.IID, 6, mf_ctlPrsXListener);
                   addEventListener(__ctlPrsX.IID, 7, mf_ctlPrsXListener);
              return mf_ctlPrsXListener.addListener(listener);
          * Removes the specified listener from the set of Listeners that
          * will be notified when events occur.
          * @param listener the listener to remove.
          * @return true if the set of listeners contained the specified
          *         listener, false otherwise.
         public boolean remove__ctlPrsXListener(__ctlPrsX listener) {
              boolean bRtn = mf_ctlPrsXListener.removeListener(listener);
              if (mf_ctlPrsXListener.isEmpty()) {
                   removeEventListener(__ctlPrsX.IID, 1, mf_ctlPrsXListener);
                   removeEventListener(__ctlPrsX.IID, 2, mf_ctlPrsXListener);
                   removeEventListener(__ctlPrsX.IID, 3, mf_ctlPrsXListener);
                   removeEventListener(__ctlPrsX.IID, 4, mf_ctlPrsXListener);
                   removeEventListener(__ctlPrsX.IID, 5, mf_ctlPrsXListener);
                   removeEventListener(__ctlPrsX.IID, 6, mf_ctlPrsXListener);
                   removeEventListener(__ctlPrsX.IID, 7, mf_ctlPrsXListener);
                   mf_ctlPrsXListener = null;
              return bRtn;
    }Filename: _ctlPrsX.java (this file includes sAbout reference)
    * Generated on Sun Sep 14 14:43:08 PDT 2008
    * This class was 100% generated by the SWTtoCOM Type library
    * generator.  Please do not edit this class manually since
    * all changes will be lost on the next generation.
    package prsx;
    import au.com.swz.swttocom.swt.types.IAutomationObject;
    import au.com.swz.swttocom.swt.types.TypeUtils;
    import au.com.swz.swttocom.swt.types.pointer.IntPointer;
    import au.com.swz.swttocom.swt.types.pointer.StringPointer;
    import au.com.swz.swttocom.swt.types.pointer.VariantPointer;
    import org.eclipse.swt.internal.ole.win32.GUID;
    import org.eclipse.swt.ole.win32.Variant;
    public interface _ctlPrsX extends IAutomationObject {
         static GUID IID = TypeUtils.IIDFromString("{4F0E0D87-ABE3-4B53-A25F-BCD5CD8F4CC7}");
         public String sAbout();
         public void unInit();
         public String sDecode(StringPointer sCID, VariantPointer bBuf);
         public String sInit(IntPointer iCom);
         public boolean rFInit();
         public boolean rFStartClass(StringPointer className);
         public boolean rFStartClassSP(StringPointer className);
         public boolean rFStartQt(StringPointer correctAnswer);
         public boolean rFStartQtHW();
         public boolean rFStartQtSP();
         public boolean rFStopQuestion();
         public boolean rFStopClass();
          * Constructs a Variant representation of this interface that can then
          * be used to pass this interface as a parameter to methods.
          *@return a Variant representation of this interface.
         public Variant createSWTVariant();
         

    After a lot of searching, I had to resort to a second query as follows:
    $getID = mysqli_fetch_assoc(mysqli_query($conn, "SELECT photodate FROM table WHERE ref = $t"));
    $pdate = $getID['photodate'];
    $pdate= (date('d/m/Y', strtotime($pdate)));
    <td>Pictured : $pdate </td>
    produced the correct output.
    Moral - if you work at it long enough there is aways a way!
    Have fun!
    Howard Walker

  • Use of Call Function Node vi, with char type pointer

    I want to be able to use a certain function from C++ DLL, and I followed the TOOLS>>IMPORT>>SHARED LIBRARY(.dll) wizard.  Where I located my header file and the dll file.
    However i am getting an error (1097).  This is the function with the paramaters:
    void Function_Name(unsigned char *L, unsigned char *H, unsigned in Len, unsigned char Adr);
    I don't think, that I configured my Call Function Node, correctly.  How should i set the paramaters settings of the first 2?  I have tried Numeric, unsigned (and signed) Int (32, 16), pass pointer value.  to accomodate the first two varaibles. 
    Please someone help, what should I do to accomodate the unsigned char pointers, so that I can used the function in labVIEW?

    Hi Safe,
    The error you're encountering has the following description (I'm sure you've already looked this up-posting here for clarity for other readers):
    LabVIEW:  An exception occurred within the external code called by a Call Library Function Node. This might have corrupted LabVIEW's memory. Save any work to a new location and restart LabVIEW.
    Typically, this happens for one of just a few reasons:
    Memory was overwritten (e.g. you passed a buffer of N bytes, but N+X bytes were modified, and an exception was thrown.
    A bad pointer was passed. (This is probably not the case.)
    Arguments were not passed to the function properly. (Calling conventions)
    Function wasn't called from the proper thread.
    Some other reason (only can be determined by inspecting in a debugger).
    I've attached some pictures of how I'd configure the dialog, but there are two critical things you have to know: calling conventions and thread safety. Those are things defined by the DLL. In Windows, C vs. 'Standard' (a.k.a. Pascal) calling conventions MUST be correct, as they affect how arguments are passed on the stack. If this is wrong, then, for example, where arg1 is expected to be an unsigned char *, you may actually only pass an unsigned char. Dereferencing that number as a pointer will at best crash, at worst appear to be a valid address and silently corrupt memory.
    I suggest double-checking the calling conventions. 'stdcall' is still quite common, but not the default setting in the Call Library Function dialog.
    Best regards,
    intvstefve
    intvsteve
    LabVIEW R&D
    Attachments:
    dllconfig11.JPG ‏40 KB
    dllconfig21.JPG ‏41 KB

  • Call function node exception AI SingleScan

     Hi all,
     I am running a Labview 6.1 application on Windows 2000.
     When I run the circuit to measure waveform curve on 1 input it works fine.
     But I had to introduce a measurement of 2 more inputs and now get the following exception (this happens sporadically - mainly when you have important measurements):
     "An exception occured within the external code called by a call library node......VI was stopped at Call library function node 0x239C of subVI "AI SingleScan (single-point waveform).vi".
     The call function library calls this routine out of lvdaq.dll with calling convention 'C' (otherwise the program crashed instantly).
     I hope that someone can help me solve it.
     Thnx xris.

    Hi Xris,
    I would like you to check if the information given in the following thread will solve you problem.
    http://forums.ni.com/ni/board/message?board.id=170&message.id=88345&requireLogin=False
    If the problem keeps existing please post again in this threas.
    Thanks in advance.
    Bets regards,
    Carsten Sprung
    Application Engineer
    National Instruments Germany

  • Call function POPUP_TO_CONFIRM after Excel close

    Good morning
    I have written code like this
    DATA: EXCEL TYPE OLE2_OBJECT.
      DATA: BOOKS TYPE OLE2_OBJECT.
      DATA: BOOK  TYPE OLE2_OBJECT.
      DATA: CELL  TYPE OLE2_OBJECT.
      DATA: FONT  TYPE OLE2_OBJECT.
      DATA: FILE  TYPE OLE2_OBJECT.
      CREATE OBJECT EXCEL 'EXCEL.APPLICATION'.
      CALL METHOD OF EXCEL 'WORKBOOKS' = FILE.
      CALL METHOD OF FILE 'OPEN'
        EXPORTING
          #1 = 'C:temp8D.xls'
          #2 = 1.
    CALL METHOD OF EXCEL 'CELLS' = CELL
        EXPORTING
          #1 = 6
          #2 = 'C'.
      SET PROPERTY OF CELL 'VALUE' = zak_pomoc.
    CALL METHOD OF EXCEL 'QUIT'.
      FREE OBJECT EXCEL.
    If user has modified the 8D file I want display this file on the screen, but first function POPUP_TO_CONFIRM  should ask him if he really wants to show file.
    I make it like this.
      call function 'POPUP_TO_CONFIRM'
        EXPORTING
          TITLEBAR              = 'Display report'
          TEXT_QUESTION         = 'Display report 8D?'
          DEFAULT_BUTTON        = '1'
          DISPLAY_CANCEL_BUTTON = 'X'
          START_COLUMN          = 25
          START_ROW             = 6
        IMPORTING
          answer                = ans.
             if ans eq '1'.
    DATA gs_excel TYPE ole2_object .
      DATA gs_wbooks TYPE ole2_object .
      DATA gs_wbook TYPE ole2_object .
      DATA gs_application TYPE ole2_object .
      CREATE OBJECT gs_excel 'EXCEL.APPLICATION' .
      SET PROPERTY OF gs_excel 'Visible' = 1 .
      GET PROPERTY OF gs_excel 'Workbooks' = gs_wbooks .
      GET PROPERTY OF gs_wbooks 'Application' = gs_application .
    *--Opening the existing document
      CALL METHOD OF gs_wbooks 'Open' = gs_wbook
        EXPORTING
          #1 = 'c:temp8D.xls'.
    endif.
    But there is my problem because two windows: first- asking about saving the file and the second- asking about showing the file, pop up in this same time.
    What condition should I write to call second window after this first one?
    Please, any suggestions?
    Thank you.

    Hello
    I'm just beginner and there is one thing I don't understand. Between lines
    CALL METHOD OF EXCEL 'QUIT'
    and
    FREE OBJECT EXCEL
    the window 'Do you want save changes' appears. And in that moment what is the value that says if the user chooses OK or QUIT?
    If I would know that value, I could call function POPUP_TO_CONFIRM in the right moment.

  • Call Function Destination in a background job

    I am having a problem using:
      CALL FUNCTION 'TABLE_ENTRIES_GET_VIA_RFC'
             DESTINATION p_dest
    in a background job.
    I am working on a program that would compare the same table in 2 different systems and write the differences.  It works when I run it in the foreground.  However, I want to run this in a nightly background job.  However, it is failing and I beleive that it is the result of the program needing a user to interactively logon to the remote system.
    How can I bypass the logon screen or enter information into the logon screen using a background job?
    Thanks.
    Jon

    Hi Jonathan,
    Would you like to reward some points to the poster to thank them as a part of SDN Contributor Recognition Program?
    You can click on the yellow star on the right of each post header to reward points.
    For more information:
    https://www.sdn.sap.com/sdn/index.sdn?page=crp_help.htm
    John.

Maybe you are looking for

  • SQL developer 1.5.4

    Hello, I am using sql developer 1.5.4. In the demo http://www.oracle.com/technology/obe/hol08/sqldev_migration/mssqlserver/viewlets/sqlserver_online.html?_template=/ocom/print On the new/select database creation, we can choose among oracle, access, m

  • Patch Status

     Required    Installed What are differences between required to installed?

  • Moving and Copying/Pasting Track Automation Data

    Hello, I am a fan of using track automation data to control the volume levels on the faders of my Audio Instrument tracks. I am NOT using the track automation assigned to regions, I am using the ones assigned to tracks. If I move a region, however, t

  • Why do you continue to use a G4?

    This may seem like an odd question as I assume that the obvious answer is economics for some, the need to still use OS9 for others and the fact that older G4's are cheap and highly upgradeable/hackable. I bring this up because, I-like many on here, a

  • Macbook Pro Retina 15 Inch Or 13 Inch for Business Marketing in College

    Looking to buy a macbook pro retina display for college but can't decide between the 15 inch and the 13inch will the 15 inch be to big will the 13 inch have enough power as well is it heavy to walk around campus with ?