Go Back   DriverHeaven > Forums > Software / Tools > Programming, Coding, (Web)Design
Register Members List Search Today's Posts Mark Forums Read

Reply
 
LinkBack Thread Tools Display Modes
Old Jan 14, 2006, 05:46 PM   #1 (permalink)
complete
DriverHeaven Newbie
 
Join Date: Aug 2005
Posts: 9
complete is on a distinguished road

How do I declare a string and pass it from a Visual Basic GUI to a C++ DLL?

How do I declare a string and pass it from a Visual Basic GUI to a C++ DLL?

Now I am debugging successfully. I can debug either on the Visual Basic end
or I can debug on the C++ side by using the DLL's project file and declaring
the compiled VB code as the launching executable. I have narrowed the problem
down to the way that I am declaring and passiing the string variables.
complete is offline   Reply With Quote
Old Jan 15, 2006, 01:25 AM   #2 (permalink)
pr0digal jenius
Delete Me
 
Join Date: Mar 2004
Posts: 15,115
pr0digal jenius is a name known to allpr0digal jenius is a name known to allpr0digal jenius is a name known to allpr0digal jenius is a name known to allpr0digal jenius is a name known to allpr0digal jenius is a name known to all

oooh.

I really have no idea...it SOUNDS like something you'll have to use a wrapper on to pass, although you mihgt can get away with doing some sort of conversion upon reading it instead.

And while this is a horrible answer, you may have some luck trying visual C# as well, as it has all the gui aspects of VB, and has similar power to C++
pr0digal jenius is offline   Reply With Quote
Old Jan 15, 2006, 11:58 PM   #3 (permalink)
logos1
DriverHeaven Newbie
 
Join Date: Feb 2005
Posts: 14
logos1 is on a distinguished road

this is one of the main issues that microsoft has attempted to solve with their .net framework.

the other way is to use symbol resolution and binding to a type that's recognizable by both ends. declare a char array and export it as a public symbol in your dll, and use whatever vb's equivalent to __declspec(dllimport) is to import it into your application.
logos1 is offline   Reply With Quote
Old Mar 22, 2006, 01:54 PM   #4 (permalink)
dehx
DriverHeaven Junior Member
 
Join Date: Mar 2006
Posts: 30
dehx is on a distinguished road

It would help if you told us what version of C++ and VB you are using.
dehx is offline   Reply With Quote
Reply



Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On




 

 
Powered by: vBulletin
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO 3.1.0
Artwork by Allan 'Zardon' Campbell, vBulletin implementation by Craig '5320' Humphreys based on original artwork by Ratchet.

All times are GMT -5. The time now is 06:17 AM. Copyright ©2008 DriverHeaven.net