Loading...

Getting Correct TwainSourceName string using VFP

Support for GdPicture Light Imaging Toolkit and GdPicture Pro Imaging ActiveX/SDK.

Getting Correct TwainSourceName string using VFP

Postby 2basix » Sat May 26, 2007 1:27 pm

Hi there,

The functions provided by the GDxxx OCX are 1 character to long for
use in Visual Foxpro applications.
To get a correct String, strip 1 character at the end.

cGetSource=TwainGetSourceName(1)
cGoodVFPString=SUBSTR(cGetSource,1,LEN(cGetSource)-1)

The reason for that is that the TwainGetSourceName(x) function
returns a string with a chr(0) at the end !!! ( a string terminator in eg C++ )
You have to strip this 1 character in order to get a correct Foxpro string.

Hope this helps all you Foxpro addicts out there.

Greetings,

Leo
--== Keep IT Basic ==--
User avatar
2basix
 
Posts: 7
Joined: Wed May 23, 2007 1:23 pm
Location: Netherlands

Postby Loïc » Tue May 29, 2007 10:58 am

Hi Leo. Thanks for this repport.

For the next release I will remove the end chr(0) from the returned string.


Regards,

Loïc
Loïc Carrère, support team.
www.orpalis.com
User avatar
Loïc
Site Admin
 
Posts: 4430
Joined: Tue Oct 17, 2006 10:48 pm
Location: France


Return to GdPicture [Pro] ActiveX

Who is online

Users browsing this forum: No registered users and 1 guest

cron