LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How do I view printf messages from a DLL called in LabVIEW?

I have LV 7.1. I am using a CLN to link in a DLL created with Borland C++ Builder v5.0. The code is written in C and I would like to use printf messages in the debug process. What do I need to do?
0 Kudos
Message 1 of 4
(4,332 Views)
I am not really sure, but I have an idea. I think you need to have code in your dll that open up a message window and direct the printf messages to that window. I have not done this myself, but I do know that printfs don't work on LabVIEW.

Maybe someone else has a better idea.
Bob
Message 2 of 4
(4,329 Views)
Take a look at the manual "Using External Code in LabVIEW". Look for the function DbgPrintf.
0 Kudos
Message 3 of 4
(4,318 Views)
I think the easiest thing to do is call OutputDebugString from kernel32.dll. You can catch the output with DbgView, a really handy utility from sysinternals.com.

Good luck,
Joe
0 Kudos
Message 4 of 4
(4,316 Views)