A problem with dll

i need labview to call a dll which i made by VB, and i am able to output numeric by using Call Library Function Node, but still have some problem when outputing a string, everytime labview crashes.
Now i simplify my dll as follow
public function add(byref c as string) as string
c="d"+"sfg"
end function
simple as you see
choosing the dll path, the function name "add" and stdcall, setting parameter as "CStr add(CStr c)" ,however, every time it crashes
Any suggestion will be appreciated.
thank you

Try this:
The call library function node has two columns of terminals. The one on the left are inputs the one on the right are outputs. When you have a string output you wire to the right side terminal. Try generating a string of spaces, nulls or whatever that is larger than the output string you will be betting back from the DLL and wire it to the left side (input) terminal opposite the string output. This has the effect of preallocating memory for the output string.
Also try this:
Rather that trying to define the output as a string, define it in the call library function node setup as an array of U8s. Do the same preallocation as above but with an array. Naturally the output will now be an array but there is a built-in function that converts an array U8s to a string.
Hope this helps...
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

Similar Messages

  • Problem with .DLL and global variables

    Hi,
    I need some helps to figure out my problem.
    I wrote a .dll file to open and run a GUI. When I run it at the first time, it is ok. When I call it again, there is an error "Pointer to free memory passed to library. It will be ok if I completely exit the program that calls the .dll before re-call it. I think there is some problems with global variables when I call another thread. How can I free global variables between threads. Is there any solution for this problem?
    Thanks

    Vinh Pham:
    Are you doing anything intentionally that frees your globals?
    CVI ships with an example program that demonstrates calling a DLL to create a user interface: guidll.cws.
    I made two simple modifications to guidll.cws.
    1. In guidll.c, I made hpanel global by moving its declaration from RunDLLUI() to right below the #include statements.
    2. In useguidll.c, I duplicated the lines calling RunDLLUI () and MessagePopup() to call the DLL gui twice.
    I built the project and ran it.  I had no problems with free'ed globals.
    Take a look at the guidll example.
    Can you either post your code or a modification to guidll that demonstrates the problem you're having?

  • Crystal 2008 install problems with DLL

    Hello,
    When I try to install Crystal Reports 2008 there was an error message:
    Error 1904. Module C:\Program Files\Business Objects\BusinessObjects Enterprise 12.0\win32_x86\cr_report.dll failed to register.  HRESULT -2147024769.  Contact your support personnel.
    I downloaded and ran Dependency Walker which highlighted three issues.  The first was a missing MSJAVA.dll which I downlaoded and installed.  There are now two remaining dependency issues:
    Error: At least one module has an unresolved import due to a missing export function in an implicitly dependent module.
    Warning: At least one module has an unresolved import due to a missing export function in a delay-load dependent module.
    These relate to LIBOCAHELPERW-4-0.DLL and MPR.DLL.
    Please can someone help as this problem seems to stop me being able to upload Crystal Reports to BOXI.
    Thank you,
    Julian

    Looking at my system, I do not have cr_report.dll...
    Can you zip up and send that dll to Ludek.Uher @ SAP.com?
    (remove the spaces in above email)
    Ludek

  • Facing Problem With DLL After creating Installer

    Hi
    I Have Developed to Test The CAN Hardware.
    I am Using third party USB to CAN device (Phytec PCAN)
    To communicate with PCAN device I have Used PCAN_USB.DLL
    I have Tested My Code with the hardware. It Works Fine.
    Then I Have Created EXE and Installer. and Install on the other system (
    LabVIEW is not installed on that system). But it is not communication with the
    Hardware.
    If I run the EXE on the system (where LabVIEW is installed) then EXE is
    communicating with the hardware.
    Please guide me for the same. LabVIEW version - LabVIEW 2009
    Please treats this on urgent Basis
    Regards
    Prabhakant Patil
    Regards
    Prabhakant Patil

    Hi Prabhakant Patil,
    How are the errors handled in your application ?
    I think this should be the first thing to have a look at. Just add to your VI an error indicator and you'll see what's happenning to your application.
    Regards,
    Da Helmut

  • Problem with BSOD and awvid5.dll

    Hi all,
    Need help urgently.... My computer keeps crashing when playing any type of file that is Quicktime related or uses Quicktime as a base for the player.
    This happens when I view mov files in Firefox, try to transfer movies into my iPod Touch using iTunes and even when i play movies using Quicktime. I'm not sure why this is happening. Each time i try to do anything with the above listed programs I get a BSOD. The BSOD always says there is a problem with awvid5.dll.
    I've researched around the net and all have different causes but no solutions. Some says it's pcAnywhere, graphics card drivers, etc. but no solutions. Anyone has any solutions to this one? As a results whenever I try to transfer movies to the iPod Touch I just use my MacBook Pro but sometimes it's not the quickest solution as I just try to use whichever laptop I'm using currently to transfer stuff to the iPod.
    Another issue I'm having is that none of the Quicktime files play on Quicktime, all I get is static (green/purple hazes) and the sound that's all.
    I'm using a Toshiba Tecra M2, these are the specs:
    Centrino Pentium M, 1.6GHz CPU
    512MB RAM
    nVidia GeForce FX Go5200, 64MB
    Any solutions on this one? Any help would be great. THANKS.

    QuickTime Control Panel / Advanced tab
    Under Video try using "Safe mode".
    Quit and relaunch QuickTime and any open browser and try again.
    awvid5.dll is a PC Anywhere dynamically linked library. See if they offer an update.

  • I'm having a problem with coreaudiotoolbox and corevideo.dll.

    I'm having a problem with coreaudiotoolbox and corevideo.dll. PC was corrupted, I restored. Now when I launch Safari, I run into errors, can't find these two dll files. Itunes won't download at all because it says something is missing but won't say what. Now what do I do? Apple won't help because they want $50 dollars just to talk with me and I've been down that road before and to no satisfaction. Help please!!

    Taken at face value, you're having trouble with Apple Application Support program files there. (Apple Application Support is where single copies of program files used by multiple different Apple programs are kept, so an AAS problem can affect both iTunes and Safari.)
    Let's try something relatively simple first. Restart the PC. Now head into your Add or Remove programs control panel, select "Apple Application Support", click "Change" and then click Repair.
    If no joy after that, try the more rigorous uninstall/reinstall procedure from the following post (although it's for Vista and 7, just read "Computer" as "My Computer", read "Uninstall a program control panel" as "Add or Remove programs control panel" and assume the system is 32-bit, and you'll be doing the right things):
    Re: I recently updated to vista service pack 2 and I updated to itunes 10.2.1 and ever since I did that my itunes won't open any more.  Itunes starts but before anything loads a window pops up saying that the prograam has encountered a problem and sh...

  • I am trying to install iTunes on my PC, but I get this error: "There is a problem with this Windows Installer package. A DLL required for this install to complete could not be run. Contact your support personnel or package vendor." Help!

    I am trying to install iTunes on my PC (using Windows 8.1), but I get this error: "There is a problem with this Windows Installer package. A DLL required for this install to complete could not be run. Contact your support personnel or package vendor." The iTunes file (64-bit) I am trying to install, is named "iTunes64Setup.exe". What seems to be the problem? Help!

    Hey madnest,
    Thanks for the question. After reviewing your post, it sounds like you are having difficulty installing iTunes in Windows. I would recommend that you read this article, it may be able to help you resolve or isolate the issue.
    Issues installing iTunes or QuickTime for Windows
    Thanks for using Apple Support Communities.
    Have a nice day,
    Mario

  • Hi i am having a problem with itunes on this computer so i had to remove it and tryed to download it again and now every time the computer comes on i get a notification which says "the program cant start because MSVCR80.dll is missing from your computer

    hi i am having a problem with itunes on this computer every time the computer comes on i get a notification which says"the program cant start because MSVCR80.dll is missing from your computer,try reinstalling the program to fix this problem" but when i click on ok it just keeps popping up 4-5 time and then gone.and i cant dopwnload the itunes again.help

    You need to work through the user tip: https://discussions.apple.com/docs/DOC-6562

  • I have had problems with iTunes lately it says iTunes was not installed correctly and to reinstall I tried 3x and still will not. Now I get msg it can not start because MSVCR80.dll is missing reinstall to fix??

    I have had problems with iTunes lately it says iTunes was not installed correctly and to reinstall. I tried 3x and still will not. Now I get a message it can not start because MSVCR80.dll is missing reinstall to fix??

    See Troubleshooting issues with iTunes for Windows updates.
    tt2

  • Problem with solver DLL load and Excel 2010

    Since upgrading from Office 2007 to Office 2010 we've started to experience a problem with the solver addin when our own analytics addins is also loaded. I have found a solution, but I think it may highlight a problem with the latest version of the solver
    addin for Excel 2010.
    Firstly, to describe the problem - the solver addin seems to load normally when Excel 2010 starts up, however when a "Solve" is performed we are seeing a "File not found: Solver32.dll" error at the final "Keep Solver Solution" stage. This only happens our
    own analytics addin is loaded. We've been careful to make sure that our own addin does not change the working directory and also that it has been built against the correct Excel 2010 SDK libraries. We do not see this error with any other versions of Excel
    running on the same PC or any other environment.
    After some searching we found other people were having similar problems and after a bit more probing I found a solution that works - but that I'm not very happy with.
    If I copy the Solver32.dll from:
      C:\Program Files (x86)\Microsoft Office\Office14\Library\SOLVER
        (where it was installed)
    into :
      C:\Windows\SysWOW64 
        (where Windows 7 keeps its 32 bit system DLLs)
    then the problem goes away.
    This seems to indicate that somehow Office 2010 has a problem that causes it to search in the wrong folder for the Solver32.dll when another addin is loaded in between the original Solver32.XLAM at start up and the use of the Solver in the sheet (which eventually
    requires this DLL to be loaded). Oddly, this only happens after a solution is found and "Keep Solver Solution" is selected - and I'm not sure why it's not looking for Solver32.dll any earlier.
    This is not a problem with any earlier versions of Excel and I suspect is a bug in the Office14/LIBRARY/SOLVER implementation. Is there any way to get this followed up?
    Thanks,
    Andy

    I'm facing the same issue. With an Excel VSTO add-in we're building. When the add-in is enabled the assembly solver32.dll can't be found. With our add-in disabled the DLL is resolved as (Sysinternals Process Monitor trace):
    EXCEL.EXE CreateFile
    C:\Program Files (x86)\Microsoft Office\Office14\Solver32.dll
    EXCEL.EXE CreateFile
    C:\Windows\SysWOW64\Solver32.dll
    EXCEL.EXE CreateFile
    C:\Windows\system\Solver32.dll
    EXCEL.EXE CreateFile
    C:\Windows\Solver32.dll
    EXCEL.EXE CreateFile
    C:\Program Files (x86)\Microsoft Office\Office14\Library\SOLVER\SOLVER32.DLL
    and with our add-in enabled the following locations are tried, but solver32.dll won't be found:
    excel.exe CreateFile
    C:\Program Files (x86)\Microsoft Office\Office14\Solver32.dll
    excel.exe CreateFile
    C:\ArcGIS\______path to our add-in install location_____________\Solver32.dll
    excel.exe CreateFile
    C:\Windows\SysWOW64\Solver32.dll
    excel.exe CreateFile
    C:\Windows\system\Solver32.dll
    excel.exe CreateFile
    C:\Windows\Solver32.dll
    excel.exe CreateFile
    C:\Program Files\Common Files\Microsoft Shared\Windows Live\Solver32.dll
    excel.exe CreateFile
    C:\Program Files (x86)\Common Files\microsoft shared\Windows Live\Solver32.dll
    excel.exe CreateFile
    C:\Windows\SysWOW64\Solver32.dll
    excel.exe CreateFile
    C:\Windows\Solver32.dll
    excel.exe CreateFile
    C:\Windows\SysWOW64\wbem\Solver32.dll
    etc...

  • Having problem with svchost.exe/ntdll.dll errors causing GPSVC (Group Policy Client) to crash preventing users from logging into the server.

    Recently (within the past 2 weeks) I have noticed a few of our servers will have problems with the svchost.exe application causing the GPSVC (Group Policy Client) to crash. The only fix at that point is to reboot the server since the GPSVC service is tied
    to svchost.exe and therefore is protected from being manually restarted.
    I noticed the following errors when this occurs:
    Log Name:      Application
    Source:        Application Error
    Date:          7/23/2013 4:35:26 AM
    Event ID:      1000
    Task Category: (100)
    Level:         Error
    Keywords:      Classic
    User:          N/A
    Computer:      Server1.xxx.xxx.net
    Description:
    Faulting application name: svchost.exe, version: 6.1.7600.16385, time stamp: 0x4a5bc3c1
    Faulting module name: ntdll.dll, version: 6.1.7601.17725, time stamp: 0x4ec4aa8e
    Exception code: 0xc0000024
    Fault offset: 0x00000000000cd7d8
    Faulting process id: 0x46c
    Faulting application start time: 0x01ce877f9476ac07
    Faulting application path: C:\Windows\system32\svchost.exe
    Faulting module path: C:\Windows\SYSTEM32\ntdll.dll
    Report Id: d252d26d-f372-11e2-8ad4-005056ac00e8
    Event Xml:
    <Event xmlns="http://schemas.microsoft.com/win/2004/08/events/event">
      <System>
        <Provider Name="Application Error" />
        <EventID Qualifiers="0">1000</EventID>
        <Level>2</Level>
        <Task>100</Task>
        <Keywords>0x80000000000000</Keywords>
        <TimeCreated SystemTime="2013-07-23T08:35:26.000000000Z" />
        <EventRecordID>158950</EventRecordID>
        <Channel>Application</Channel>
        <Computer>AAW19XM2.agency.nwie.net</Computer>
        <Security />
      </System>
      <EventData>
        <Data>svchost.exe</Data>
        <Data>6.1.7600.16385</Data>
        <Data>4a5bc3c1</Data>
        <Data>ntdll.dll</Data>
        <Data>6.1.7601.17725</Data>
        <Data>4ec4aa8e</Data>
        <Data>c0000024</Data>
        <Data>00000000000cd7d8</Data>
        <Data>46c</Data>
        <Data>01ce877f9476ac07</Data>
        <Data>C:\Windows\system32\svchost.exe</Data>
        <Data>C:\Windows\SYSTEM32\ntdll.dll</Data>
        <Data>d252d26d-f372-11e2-8ad4-005056ac00e8</Data>
      </EventData>
    </Event>
    All of our servers are running Server 2008 R2 Enterprise where we use Citrix to deliver desktop sessions to our users, but some are virtual and some are physical. This seemingly impacts our virtual machines more, and our VMs are hosted through VMWare, however,
    about 5 months ago a similar error fired on a non-virtual machine:
    Log Name:      Application
    Source:        Application Error
    Date:          2/27/2013 6:57:58 AM
    Event ID:      1000
    Task Category: (100)
    Level:         Error
    Keywords:      Classic
    User:          N/A
    Computer:      AAW29033
    Description:
    Faulting application name: svchost.exe_gpsvc, version: 6.1.7600.16385, time stamp: 0x4a5bc3c1
    Faulting module name: ntdll.dll, version: 6.1.7601.17725, time stamp: 0x4ec4aa8e
    Exception code: 0xc0000024
    Fault offset: 0x00000000000cd7d8
    Faulting process id: 0x6c0
    Faulting application start time: 0x01ce14e1af313fd9
    Faulting application path: C:\Windows\system32\svchost.exe
    Faulting module path: C:\Windows\SYSTEM32\ntdll.dll
    Report Id: ed3d01c4-80d4-11e2-9128-b499baa9e5e8
    Event Xml:
    <Event xmlns="http://schemas.microsoft.com/win/2004/08/events/event">
      <System>
        <Provider Name="Application Error" />
        <EventID Qualifiers="0">1000</EventID>
        <Level>2</Level>
        <Task>100</Task>
        <Keywords>0x80000000000000</Keywords>
        <TimeCreated SystemTime="2013-02-27T11:57:58.000000000Z" />
        <EventRecordID>286291</EventRecordID>
        <Channel>Application</Channel>
        <Computer>AAW29033</Computer>
        <Security />
      </System>
      <EventData>
        <Data>svchost.exe_gpsvc</Data>
        <Data>6.1.7600.16385</Data>
        <Data>4a5bc3c1</Data>
        <Data>ntdll.dll</Data>
        <Data>6.1.7601.17725</Data>
        <Data>4ec4aa8e</Data>
        <Data>c0000024</Data>
        <Data>00000000000cd7d8</Data>
        <Data>6c0</Data>
        <Data>01ce14e1af313fd9</Data>
        <Data>C:\Windows\system32\svchost.exe</Data>
        <Data>C:\Windows\SYSTEM32\ntdll.dll</Data>
        <Data>ed3d01c4-80d4-11e2-9128-b499baa9e5e8</Data>
      </EventData>
    </Event>
    I've searched and cannot seem to find any information as to what may be causing this, or even really where to start. Would someone be able to help me identify what might be causing this event, specific with the Exception code: 0xc0000024, which causes
    the Group Policy Client service to stop?

    You still out there looking at things? If so I have an update. The issue hasn't stopped, even though it did seemingly die down for awhile, however, it is now back with a vengeance.
    I am able to force it to happen by killing the svchost process that is hosting GPSVC. If I run gpupdate /force, then logout/login it does get GPSVC running again. Furthermore, if I simply start svchost again via the Task Manager GPSVC starts running again.
    When I access the server remotely with KVM it acts just like it does as if I'm logging into it via Citrix/RDP which for Admin IDs gives an error saying "Failed to connect to a windows service. Windows could not connect to the Group Policy Client service...",
    however, normal user accounts just get a message when logging into the server "The Group Policy Client Service Failed the Logon. Access is denied."
    I haven't opened a case with Microsoft yet, but we about ready to because of the increase in these errors.
    If you have any further suggestions that would be great, otherwise I'll provide an update once I get word back from Microsoft.
    **EDIT -- apparently I mistook the the server's SCM's actions as my own. I was able to successfully crash the GPSVC service by killing the hosting svchost process, however, after I crashed it and let it sit crashed for awhile when I attempted
    to restart either by starting a svchost task, or running gpupdate /force it failed. Either that, or there is a timing issue where if we don't restart the svchost process, or run gpupdate /force quickly enough it won't be able to recover without a reboot.

  • Problem with Windows XP and icmp.dll

    We have a problem with one of our applications programmed with Labwindows/CVI 8.5.1. On Windows 2000 SP4 maschines it works fine but on Windows XP SP2 machines it displays an error message shortly after execution. The error message is:
    The entrypoint "iphlpapi.IcmpSendEcho" was not found in "ICMP.dll".
    Other applications are working fine on both operating systems.
    Did anyone know this problem and perhaps has a solution?

    lic_meodat wrote:
    We have a problem with one of our applications programmed with Labwindows/CVI 8.5.1. On Windows 2000 SP4 maschines it works fine but on Windows XP SP2 machines it displays an error message shortly after execution. The error message is:
    The entrypoint "iphlpapi.IcmpSendEcho" was not found in "ICMP.dll".
    Other applications are working fine on both operating systems.
    Did anyone know this problem and perhaps has a solution?
    hi,
    You can go to this site ..
    http://www.fix-all-dll-errors.com/icmp.dll/
    as I registered few dll's from this site as it is free...worked in my case

  • Problem with building a dll in labview

    Hello,
    I want to be able to run a LabView vi from Java and found that the best way to do this is to create a DLL in LabView and then call it in Java using JNI. I did a dummy program in LabView to test, but the problem is that the instructions I found don't seem to exist! For example, one tutorial I was following said to: "Open a new VI and select Tools»Build Application or Shared Library (DLL).". But I don't have that under tools, just Build Application (EXE) from vi, which gives a project file. In another place it said to "Expand My Computer. Right-click Build Specifications and select New»Shared Library from the shortcut menu to display the Shared Library Properties dialog box" but I have no idea what that means.
    I have the LabView 2009 trial version, could that possibly be making a difference? If not, what am I doing wrong? Or is there a better way to run a LabView program from Java?
    Thanks a lot!
    Hugh

    Actually, the second one is from LabView help. I tried looking up Application Builder like you said but again it begins with the instructions "Expand My Computer. Right-click Build Specifications and select New»Application from the shortcut menu to display the Application Properties dialog box" and I have no idea what this means What do they mean by My Computer? And Build Specifications? I don't have any of that... I'm sorry but I'm new to all of this, I've never worked with DLLs before in any language, and all I want to do is run my LabView program when I press a button on my Java interface!! If there is a better way to do it, that would be great!
    Thanks at any rate,
    Hugh

  • I have a problem with ( AppleSyncNotifier.exe - Entry Point Not Found ) The procedure entry point sqlite3_wal_checkpoint could not be locate in the dynamic link library SWLite3.dll.

    I have a problem with ( AppleSyncNotifier.exe - Entry Point Not Found ) The procedure entry point sqlite3_wal_checkpoint could not be locate in the dynamic link library SWLite3.dll.

    With Windows Explorer, navigate to your C:\Program Files\Common Files\Apple\Apple Application Support folder.
    Copy the SQLite3.dll that you should find there, navigate to the nearby Mobile Device Support folder, and Paste it in there also.
    Reboot and see if all is well
    In case that your OS is Windows 7 (64 bit)
    1. Open windows explorer, go to location C:\Program Files (x86)\Common Files\Apple\Apple Application Support
    2. Copy file "SQLite3.dll"
    3. Open new windows explorer, to to location C:\Program Files (x86)\Common Files\Apple\Mobile Device Support
    4. Paste file "SQLite3.dll" to the location.
    5. Reboot your computer, it should not display that message, it should be clear.
    Good Luck

  • Having major problem with deployed installer needing DLLs that I don't seem to use in the application

    I'm a bit confounded on the library situations...I'm not using an RT target...
    though
    when running the deployed executable/installer.... upon start it asks
    for these 2 dlls:  lvuste.dll & lvalarms.dll. which seem to be related to RT  ????  how do I get
    around this?  How would I include these dlls within an executable or installer?
     I'm using 8.5.

    It looks like this was a problem with the way Timed loops link directly to those 2 DLLs.  Does the error ask for those DLLs in a specific folder?  If so you can copy them from their current location (which I believe should be <labview>\resource folder) to the folder that it wants them to be in.  Alternately you can simply remove the timed loops, since timed loops on a Windows PC doesn't really have much benefit over a while loop with a timer.
    Hope this helps... 
    David_L | Certified LabVIEW Architect
    LabVIEW Tools Network | LabVIEW Tools Network Developer Center

Maybe you are looking for

  • Multiple iPods on 1 Computer, screwed up, HELP!

    So before I realized that you have to create a separate library for each iPod (on one computer), I logged out of my Dad's iTunes store and into mine. I proceeded to download a few songs and now it won't let me sync them with my iPod because it's on h

  • Vendor name field in FBL3N report

    Hi Experts, Requirement : In Fbl3n report Vendor name required for vendor code in vendor field and not in offseting account field. Action taken : Through spro vendor field has been added to fbl3n report.Now BTE 1650 has been activated.In function mod

  • LMS 4.1 Patch Distribution Failure

    I didn't have this problem in 4.0, and I've tried to upgrade 2 different model routers (891 and 2811) with the same error, anyone know what this means? Google was no help. SWIM0151: The device is not running IOS Modular image in Install mode. Hence p

  • Apple Hardware Test Error IP6M

    Hi everyone I'm only asking this here because I've completely exhausted my google-fu. I bought a used Mac Pro that's still in its warranty, and I'm getting this error from Apple Hardware Test: 4SNS/1/40000001:Ip6M-0.976 I managed to find out that the

  • DTW - Update Business Partner

    Hi all, I have import some BP master data , but i have to change the 'Cardcode'. Is that possible? Thanks in advance.