AutoHotkey Homepage AutoHotkey Community
Let's help each other out
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Embed an Internet Explorer control in your AHK Gui via COM
Goto page Previous  1, 2, 3, 4, 5 ... 11, 12, 13  Next
 
Post new topic   Reply to topic    AutoHotkey Community Forum Index -> Scripts & Functions
View previous topic :: View next topic  
Author Message
Sean



Joined: 12 Feb 2007
Posts: 1388

PostPosted: Tue May 15, 2007 12:14 am    Post subject: Reply with quote

Titan wrote:
The about: URI scheme is an unofficial feature in IE, which ironically dropped support for the more advanced data: standard in v7.

Thanks for the link.
Actually I had hit the page too, but I didn't read it carefully, just scanned the tables about the mention of (Raw) HTML...
Back to top
View user's profile Send private message
majkinetor



Joined: 24 May 2006
Posts: 3644
Location: Belgrade

PostPosted: Tue May 15, 2007 6:49 am    Post subject: Reply with quote

2freakkk
Yes, that was my thought too. I already told AGU that it can be done on keypress now. About easines, wrappers provide the same easines as integrated controls, at least for me.
_________________
Back to top
View user's profile Send private message MSN Messenger
daonlyfreez



Joined: 16 Mar 2005
Posts: 755
Location: Berlin

PostPosted: Tue May 15, 2007 7:34 am    Post subject: Reply with quote

Great stuff, but haven't been able to read thru the new posts yet.

I tried adding multiple controls to an AHK-Gui, and succeeded in adding multiple Internet Explorer controls (great for a tabbed-browser), but cannot get the Mozilla ActiveX control to work anymore...

Anybody?

Download (includes Mozilla ActiveX) (~ 6MB zipped)

Run registerMozAx.ahk once, to register the Mozilla ActiveX, then try MultipleBrowserControlTest.ahk.



The first control should be a Mozilla control, the second an Internet Explorer control. But apparently they are both Internet Explorer.

I modified the #include file (Gui_BrwsControl.ahk) to feed it the instance of the control and did some other changes.

Please check what goes wrong.
_________________
(sorry, homesite offline atm)


Last edited by daonlyfreez on Sun Nov 02, 2008 1:48 pm; edited 1 time in total
Back to top
View user's profile Send private message
Sean



Joined: 12 Feb 2007
Posts: 1388

PostPosted: Tue May 15, 2007 12:55 pm    Post subject: Reply with quote

daonlyfreez wrote:
The first control should be a Mozilla control, the second an Internet Explorer control. But apparently they are both Internet Explorer.

I don't really want to install ActiveX for Mozilla/Firefox.
Fortunately, however, there is a way to peek into it without actually installing it, thanks to oleview/tlb.
The TypeLib is resident in mozctl.dll, and to my surprise, it just implemented WebBrowser controls provided by MS, i.e., identical to that of IE.
So, there seems to be no reason/benefit to use it over that of IE.
Back to top
View user's profile Send private message
Chris
Site Admin


Joined: 02 Mar 2004
Posts: 10474

PostPosted: Tue May 15, 2007 1:15 pm    Post subject: Reply with quote

Sean wrote:
Chris, would you split this thread as you suggested?
It has been split. Feel free to edit this new topic's title.

Edit: For reference, the old topic is http://www.autohotkey.com/forum/viewtopic.php?t=15885.


Last edited by Chris on Tue May 15, 2007 4:58 pm; edited 1 time in total
Back to top
View user's profile Send private message Send e-mail
Sean



Joined: 12 Feb 2007
Posts: 1388

PostPosted: Tue May 15, 2007 1:27 pm    Post subject: Reply with quote

Chris wrote:
It has been split. Feel free to edit this new topic's title.

Thanks. BTW, I like the title, very comprehensive.
Back to top
View user's profile Send private message
Sean



Joined: 12 Feb 2007
Posts: 1388

PostPosted: Tue May 15, 2007 1:44 pm    Post subject: Reply with quote

I changed the prefix from Gui_IE to IE_.
And, I dropped the last (url) parameter from IE_Add().

BTW, I'd like to hear opinions about whether the variable pwb should be kept as Global or not.
Back to top
View user's profile Send private message
daonlyfreez



Joined: 16 Mar 2005
Posts: 755
Location: Berlin

PostPosted: Tue May 15, 2007 1:49 pm    Post subject: Reply with quote

Quote:
BTW, I'd like to hear opinions about whether the variable pwb should be kept as Global or not.


If possible, it would be good to have as little Global variables as possible. Did you check the code from my multiple browser controls script? I added an index to be able to differentiate between multiple controls. This meant I had to add extra Global vars (pwb1, pwb2, hCtrl1, hCtrl2), which is cumbersome, since adding more controls would require an extra pair of Global vars.
_________________
(sorry, homesite offline atm)
Back to top
View user's profile Send private message
majkinetor



Joined: 24 May 2006
Posts: 3644
Location: Belgrade

PostPosted: Tue May 15, 2007 1:56 pm    Post subject: Reply with quote

Sean, drop the global.
You should use handle as a parameter to each function as I did with HiEdit. This allows multiple controls to be created and manipualted.

Quote:
I changed the prefix from Gui_IE to IE_.
And, I dropped the last (url) parameter from IE_Add().

This is good.

I think you should not support Mozilla. FF fans can do it themselves. IE control is not ment to be used as a browser anyway, but as a handy way to represent data using html or visit hardoced pages for script news etc..


Other notes
- Post your control at autothotkey.net and link to it. That way filename will be suggested and you will easier maintain thread starter.

- Instad wrapper, just post current API as I did in the wiki. This allows users to see what's in in consize way, not by reading the control source.

- You can post short example of usage, again, you have it at wiki or you can post more advanced one (or anybody else wiling to do it).
_________________


Last edited by majkinetor on Tue May 15, 2007 2:01 pm; edited 3 times in total
Back to top
View user's profile Send private message MSN Messenger
Sean



Joined: 12 Feb 2007
Posts: 1388

PostPosted: Tue May 15, 2007 1:59 pm    Post subject: Reply with quote

daonlyfreez wrote:
If possible, it would be good to have as little Global variables as possible. Did you check the code from my multiple browser controls script? I added an index to be able to differentiate between multiple controls. This meant I had to add extra Global vars (pwb1, pwb2, hCtrl1, hCtrl2), which is cumbersome, since adding more controls would require an extra pair of Global vars.

Yes, that was the main reason why I was asking. It's cumbersome to use with multiple instances.
And, personally I don't like to have it as global.
Back to top
View user's profile Send private message
daonlyfreez



Joined: 16 Mar 2005
Posts: 755
Location: Berlin

PostPosted: Tue May 15, 2007 2:04 pm    Post subject: Reply with quote

Quote:
I think you should not support Mozilla. FF fans can do it themselves.


Since the Mozilla ActiveX control requires almost if not exactly the same COM code, it would be nice and easy to create the BrowserControlLib to support both. That would prevent reusing existing code for both possibilities (Internet Explorer or Mozilla ActiveX).

I'll continue trying controlling the Mozilla ActiveX. Maybe dealing with multiple controls and prevent the use of Global vars could be handled in the meantime.
_________________
(sorry, homesite offline atm)
Back to top
View user's profile Send private message
Sean



Joined: 12 Feb 2007
Posts: 1388

PostPosted: Tue May 15, 2007 2:21 pm    Post subject: Reply with quote

daonlyfreez wrote:
I'll continue trying controlling the Mozilla ActiveX. Maybe dealing with multiple controls and prevent the use of Global vars could be handled in the meantime.

I can't really tell if it'll solve the issue, but, would you try after replacing

Code:
GUID4String(CLSID_WebBrowser, "{1339B54C-3453-11D2-93B9-000000000000}")
GUID4String(CLSID_WebBrowser, "{8856F961-340A-11D0-A96B-00C04FD705A2}")

to

Code:
CLSID_WebBrowser := "{1339B54C-3453-11D2-93B9-000000000000}"
CLSID_WebBrowser := "{8856F961-340A-11D0-A96B-00C04FD705A2}"


You may replace IID_IWebBrowser2 too like

Code:
IID_IWebBrowser2 := "{D30C1661-CDAF-11D0-8A3E-00C04FC9E26E}"
Back to top
View user's profile Send private message
Chris
Site Admin


Joined: 02 Mar 2004
Posts: 10474

PostPosted: Tue May 15, 2007 5:02 pm    Post subject: Reply with quote

daonlyfreez wrote:
Chris, could you move my last comment from the previous thread to the new one too?
I can't move it directly, but I can just quote it here:
daonlyfreez @15 May 2007 09:24 am wrote:
True, the developer created an interface that equals the calling scheme of that of the Internet Explorer control, therefore it should be trivial to use as a possible replacement for Internet Explorer.

The Mozilla ActiveX was only supposed to be an alternative if Internet Explorer is not installed, not as a required download. Yet, still I would like to be able to get it to work Razz
Back to top
View user's profile Send private message Send e-mail
Sean



Joined: 12 Feb 2007
Posts: 1388

PostPosted: Wed May 16, 2007 4:57 am    Post subject: Reply with quote

I updated IEControl.ahk (:this thread) and CoHelper.ahk.
As they're not thoroughly tested, please report back if meets a problem.
Thanks.
Back to top
View user's profile Send private message
daonlyfreez



Joined: 16 Mar 2005
Posts: 755
Location: Berlin

PostPosted: Wed May 16, 2007 7:28 am    Post subject: Reply with quote

Great!

Thanks to your instructions, I could get the Mozilla ActiveX to work in the meantime Cool

Will check out your updated code, and adapt mine.
_________________
(sorry, homesite offline atm)
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    AutoHotkey Community Forum Index -> Scripts & Functions All times are GMT
Goto page Previous  1, 2, 3, 4, 5 ... 11, 12, 13  Next
Page 4 of 13

 
Jump to:  
You can post new topics in this forum
You can reply to topics in this forum


Powered by phpBB © 2001, 2005 phpBB Group