ActiveForm and ISAPI

How can I post a request to ISAPI(or IIS) in my ActiveForm to ask the ISAPI to send a html file to IE to display?
zxwAsked:
Who is Participating?
 
intheConnect With a Mentor Commented:
hi,

from a faq:

Q: I've built an ActiveX control that can be put in the Internet Explorer. How can I make it send the browser to another URL?

A: Use the HLinkNavigateString function that's part of the WinINet API.
so add wininet to your uses section . This function takes two arguments: a pointer to an COM object and a string that represents the URL to go to.

If you've built an ActiveX control, the COM object to pass for the first parameter is the same object that was generated by the ActiveX control wizard. If you're invoking the HLinkNavigateString function from within a method of this object, you can pass Self as this parameter.

Example:

  HLinkNavigateString( Self, 'http://www.borland.com' );

If you're building an ActiveForm, the wizard generates a form class (derived from TActiveForm), but the COM object is actually a standard controller object implemented by TActiveFormControl. From within a method of the form class, you can use the ComObject property to retrieve a pointer to the form's COM controller object.

Example:

  HLinkNavigateString( ComObject, 'http://www.borland.com' );

The Microsoft WinINet API also includes functions to cause the browser to move forward or backward in the browser history, as if the user presed the forward or backward buttons. These functions are listed below.

function HlinkGoBack(pUnk: IUnknown): HResult; stdcall;
function HlinkGoForward(pUnk: IUnknown): HResult; stdcall;

The pUnk parameter in each of these is the same COM object: either Self in the case of an ActiveX control, or ComObject in the case of an ActiveForm.
Sample code
Download this ZIP file:
http://pweb.netcom.com/~cherrman/hlink.zip
(28KB) into a directory called c:\daxfaq\hlink, and unzip the contents. Build the project, and load the supplied HTML page.
This sample demonstrates the three kinds of HLink* functions, and also shows how to obtain the Internet Explorer's LocationURL property from the page the ActiveX is embedded into.
Regards Barry

0
 
intheCommented:
is this a standard form on a webpage or an activexform on a webpage?
i can give example for standard form but not activexform.
0
 
nrobinCommented:
First point - its not easy. Second point - do you mean you have an ActiveForm already embedded within IE, and you would like to navigate elsewhere?  please explain....

Nick.
0
Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

 
zxwAuthor Commented:
Yes, I want to navigate else where by send some params to my ISAPI in my activexform embedded within IE.
0
 
nrobinCommented:
Not quite sure what you mean still. ISAPI is server side, yet your component (activeXForm) is client side.

Nick.
0
 
zxwAuthor Commented:
Can I express this way:

How to make IE go to a new URL in my ActiveXForm?
0
 
zxwAuthor Commented:
I am very appreciated with the answer,thank you.
0
 
zxwAuthor Commented:
I am very appreciated with the answer,thank you.
0
 
zxwAuthor Commented:
I am very appreciated with the answer,thank you.
0
 
zxwAuthor Commented:
I am very appreciated with the answer,thank you.
0
All Courses

From novice to tech pro — start learning today.