Dear Jimmy,
I think CreateBinary() could be implemented like this:
HB_FUNC( CREATEBINARY )
{
hb_retclen( hb_parc( 1 ), hb_parclen( 1 ) );
}
or maybe we simply don't need it as Harbour strings can contain embedded zeroes
IA
- Antonio Linares
- Site Admin
- Posts: 42529
- Joined: Thu Oct 06, 2005 5:47 pm
- Location: Spain
- Has thanked: 31 times
- Been thanked: 77 times
- Contact:
- Antonio Linares
- Site Admin
- Posts: 42529
- Joined: Thu Oct 06, 2005 5:47 pm
- Location: Spain
- Has thanked: 31 times
- Been thanked: 77 times
- Contact:
Re: IA
I may be wrong as according to these docs:
http://www.yaldex.com/fox_pro_tutorial/html/cad2893d-9c63-4899-83d8-e5d58f79a414.htm
We have examples of managing VT_UI1 type data in harbour/contrib/hbwin/olecore.c
look for VT_UI1 inside
http://www.yaldex.com/fox_pro_tutorial/html/cad2893d-9c63-4899-83d8-e5d58f79a414.htm
Visual FoxPro automatically converts binary data passed from an ActiveX control or automation object as an array of VT_UI1 type data to a Visual FoxPro character string. Visual FoxPro internally marks this character string as binary data passed from an ActiveX control or automation object. When the character string is passed back to an ActiveX control or automation object, Visual FoxPro automatically converts the character string to an array of VT_UI1 type data the ActiveX control or automation object expects.
We have examples of managing VT_UI1 type data in harbour/contrib/hbwin/olecore.c
look for VT_UI1 inside
- Antonio Linares
- Site Admin
- Posts: 42529
- Joined: Thu Oct 06, 2005 5:47 pm
- Location: Spain
- Has thanked: 31 times
- Been thanked: 77 times
- Contact:
Re: IA
Maybe this:
#include "hbole.ch"
lsink = CreateBinary( hb_MemoRead( "test.isf" ) )
...
function CreateBinary( cBinary )
return __oleVariantNew( WIN_VT_UI1, cBinary )
#include "hbole.ch"
lsink = CreateBinary( hb_MemoRead( "test.isf" ) )
...
function CreateBinary( cBinary )
return __oleVariantNew( WIN_VT_UI1, cBinary )
Re: IA
hi Antonio,
thx for Tip.
it seems that i need to "save" in IPF_Base64GIF instead of IPF_GIF
it will NOT produce a valid "GIF89a" so i can´t "display" it
but i can "load" it into INK simple with
it now "display" in "INK" and i can press "recognize" 
Source ( HMG Syntax) can be found here
http://www.hmgforum.com/viewtopic.php?f=5&t=7219&p=68501

thx for Tip.
it seems that i need to "save" in IPF_Base64GIF instead of IPF_GIF
it will NOT produce a valid "GIF89a" so i can´t "display" it
but i can "load" it into INK simple with
Code: Select all | Expand
lsInk := hb_MemoRead( cFile )
oInkOvl:Enabled := 0
oInkOvl:ink:Load( lsInk )
oInkOvl:Enabled := 1
// draw it
oInkOvl:Draw( oInkrectangle )

Source ( HMG Syntax) can be found here
http://www.hmgforum.com/viewtopic.php?f=5&t=7219&p=68501
greeting,
Jimmy
Jimmy
- Antonio Linares
- Site Admin
- Posts: 42529
- Joined: Thu Oct 06, 2005 5:47 pm
- Location: Spain
- Has thanked: 31 times
- Been thanked: 77 times
- Contact: