By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
455,582 Members | 1,694 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 455,582 IT Pros & Developers. It's quick & easy.

Calling API with OLE_ HANDLE parameter

P: n/a
I have a file with binary data and a dll where I have to pass a
OLE_HANDLE which points to the data in the file.

How do I read the data (i presume as binaryreader) and then pass the
OLE_HANDLE to the function?

Thomas
Nov 20 '05 #1
Share this Question
Share on Google+
2 Replies


P: n/a
Can you be more specific about which API you are calling? It may be that
just loading the bytes from a FileStream will not work if the service you
are calling expects a handle of some sort.

In searching MSDN, I only find refernces to OLE_HANDLE where it refers to a
GDI handle, like an Icon or a Bitmap from COM-interop interraces such as
IPicture. (Usually, such such handles are passed between COM and .Net as
type System.IntPtr.)

John Rivard, Visual Basic Team
This posting is provided "AS IS" with no warranties, and confers no rights.

--------------------
| From: Thomas Schoch <to**********@swissonline.ch>
| Subject: Calling API with OLE_ HANDLE parameter
| Date: Mon, 15 Sep 2003 10:01:58 +0200
| Message-ID: <q8********************************@4ax.com>
| X-Newsreader: Forte Agent 1.9/32.560
| MIME-Version: 1.0
| Content-Type: text/plain; charset=us-ascii
| Content-Transfer-Encoding: 7bit
| Newsgroups: microsoft.public.dotnet.languages.vb
| NNTP-Posting-Host: 217.11.39.245
| Lines: 1
| Path:
cpmsftngxa07.phx.gbl!cpmsftngxa10.phx.gbl!TK2MSFTN GXA05.phx.gbl!TK2MSFTNGP08
.phx.gbl!TK2MSFTNGP11.phx.gbl
| Xref: cpmsftngxa07.phx.gbl microsoft.public.dotnet.languages.vb:136897
| X-Tomcat-NG: microsoft.public.dotnet.languages.vb
|
| I have a file with binary data and a dll where I have to pass a
| OLE_HANDLE which points to the data in the file.
|
| How do I read the data (i presume as binaryreader) and then pass the
| OLE_HANDLE to the function?
|
| Thomas
|

Nov 20 '05 #2

P: n/a
John
It's a method of an ActiveX control that we are using. It reads it's
own data from the blob which has to be passed in a OLE_HANDLE.

Thomas

On Mon, 15 Sep 2003 19:45:49 GMT, jo****@microsot.com (John Rivard
[MSFT]) wrote:
Can you be more specific about which API you are calling? It may be that
just loading the bytes from a FileStream will not work if the service you
are calling expects a handle of some sort.

In searching MSDN, I only find refernces to OLE_HANDLE where it refers to a
GDI handle, like an Icon or a Bitmap from COM-interop interraces such as
IPicture. (Usually, such such handles are passed between COM and .Net as
type System.IntPtr.)

John Rivard, Visual Basic Team
This posting is provided "AS IS" with no warranties, and confers no rights.

--------------------
| From: Thomas Schoch <to**********@swissonline.ch>
| Subject: Calling API with OLE_ HANDLE parameter
| Date: Mon, 15 Sep 2003 10:01:58 +0200
| Message-ID: <q8********************************@4ax.com>
| X-Newsreader: Forte Agent 1.9/32.560
| MIME-Version: 1.0
| Content-Type: text/plain; charset=us-ascii
| Content-Transfer-Encoding: 7bit
| Newsgroups: microsoft.public.dotnet.languages.vb
| NNTP-Posting-Host: 217.11.39.245
| Lines: 1
| Path:
cpmsftngxa07.phx.gbl!cpmsftngxa10.phx.gbl!TK2MSFT NGXA05.phx.gbl!TK2MSFTNGP08
phx.gbl!TK2MSFTNGP11.phx.gbl
| Xref: cpmsftngxa07.phx.gbl microsoft.public.dotnet.languages.vb:136897
| X-Tomcat-NG: microsoft.public.dotnet.languages.vb
|
| I have a file with binary data and a dll where I have to pass a
| OLE_HANDLE which points to the data in the file.
|
| How do I read the data (i presume as binaryreader) and then pass the
| OLE_HANDLE to the function?
|
| Thomas
|


Nov 20 '05 #3

This discussion thread is closed

Replies have been disabled for this discussion.