ActiveX program

ActiveX program

Postby Dave Zowasky » Sat Jul 21, 2007 12:02 pm

Hello All,

I was wondering if it is possible to make FWH program listen and respond to another programs activex calls to it?

Thanks
Dave Zowasky
Com1 Software, Inc.
http://www.com1software.com
information@com1software.com
330 653-3771
User avatar
Dave Zowasky
 
Posts: 125
Joined: Wed Oct 19, 2005 2:28 pm
Location: Hudson Ohio

Postby Antonio Linares » Sat Jul 21, 2007 2:52 pm

Dave,

Without having further details about what you need to do, you may review Windows msg WM_COPYDATA. There is a working sample at samples\copydata_16_32

the WM_COPYDATA message is sent when an application passes data to another application

WM_COPYDATA
wParam = (WPARAM) (HWND) hwnd; // handle of sending window
lParam = (LPARAM) (PCOPYDATASTRUCT) pcds; // pointer to structure with data

Parameters

hwnd
Identifies the window passing the data.

pcds
Points to a COPYDATASTRUCT structure that contains the data to be passed.

Return Values

If the receiving application processes this message, it should return TRUE; otherwise, it should return FALSE.

Remarks

An application must use the SendMessage function to send this message, not the PostMessage function.
The data being passed must not contain pointers or other references to objects not accessible to the application receiving the data.
While this message is being sent, the referenced data must not be changed by another thread of the sending process.
The receiving application should consider the data read-only. The pcds parameter is valid only during the processing of the message. The receiving application should not free the memory referenced by pcds. If the receiving application must access the data after SendMessage returns, it must copy the data into a local buffer.

See Also

PostMessage, SendMessage, COPYDATASTRUCT
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 42102
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Postby Antonio Linares » Sat Jul 21, 2007 2:53 pm

Also, you can use sockets.

Please review samples\sockserv.prg and sockcli.prg
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 42102
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Postby Dave Zowasky » Sun Jul 22, 2007 10:52 am

Antonio,

I will give a good look at the program you mentioned.

It may be what I am looking for.

Thanks
Dave Zowasky
Com1 Software, Inc.
http://www.com1software.com
information@com1software.com
330 653-3771
User avatar
Dave Zowasky
 
Posts: 125
Joined: Wed Oct 19, 2005 2:28 pm
Location: Hudson Ohio

Postby Dave Zowasky » Sun Jul 22, 2007 12:26 pm

OK

I think I can pose my question better.


I looked at the fwcopy16 program and it may be a part of the answer to my question.

If I have an application (A) that is residing on the C drive as an exe and I wanted to make an activex call to that application from another application (B) that I am running.

Two questions.

Does application (A) need to be running or registered with operating system in any way?

And in application (B) what syntax would I use to call it?


example like:

oActiveX1 = TActiveX():New( oWnd, "Shell.Explorer" )

oPdf = TActiveX():New( oWnd, "AcroPDF.PDF" )



Let me know if I am way off.

Thanks
Dave Zowasky
Com1 Software, Inc.
http://www.com1software.com
information@com1software.com
330 653-3771
User avatar
Dave Zowasky
 
Posts: 125
Joined: Wed Oct 19, 2005 2:28 pm
Location: Hudson Ohio

Postby Antonio Linares » Tue Jul 24, 2007 12:59 pm

Dave,

What you describe seems possible to be implemented.

If you provide us some more exact details then we may be able to provide you more help
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 42102
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Postby R.F. » Tue Jul 24, 2007 3:21 pm

PMJI, I remember I saw in xHarbour.com website that the commercial version of xHarbour support ActiveX server, I mean, that you can turn your xHabour application into an ActiveX server, not only an ActiveX client.

Take a look into www.xharbour.com
Saludos
R.F.
R.F.
 
Posts: 840
Joined: Thu Oct 13, 2005 7:05 pm

Postby Dave Zowasky » Thu Aug 23, 2007 6:20 pm

Rene,

I will take a look, that sounds like what I am talking about.

Thanks
Dave Zowasky
Com1 Software, Inc.
http://www.com1software.com
information@com1software.com
330 653-3771
User avatar
Dave Zowasky
 
Posts: 125
Joined: Wed Oct 19, 2005 2:28 pm
Location: Hudson Ohio


Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: No registered users and 112 guests