Page 2 of 2 <12
Topic Options
#51308 - 2000-09-11 08:47 PM Re: OLE and Internet Explorer
Bryce Offline
KiX Supporter
*****

Registered: 2000-02-29
Posts: 3167
Loc: Houston TX
Shawn

Have you noticed that the formatting in the HTML subroutine is carried over in to the actual IE interface?

Bryce


Top
#51309 - 2000-09-11 08:58 PM Re: OLE and Internet Explorer
Shawn Administrator Offline
Administrator
*****

Registered: 1999-08-13
Posts: 8611
The <pre> </pre> tags provide preformatted style. Kinda makes for WYSIWYG authoring.

Shawn.


Top
#51310 - 2000-09-11 09:24 PM Re: OLE and Internet Explorer
Shawn Administrator Offline
Administrator
*****

Registered: 1999-08-13
Posts: 8611
This is going to sound crazy - but based on my readings, I think you could actually build a web site using KiX !

Perl/Java - Move over !

Shawn.



Top
#51311 - 2000-09-12 06:04 PM Re: OLE and Internet Explorer
Bryce Offline
KiX Supporter
*****

Registered: 2000-02-29
Posts: 3167
Loc: Houston TX
shawn do you have any idea why this stuff won't work on win9x?
Top
#51312 - 2000-09-12 07:48 PM Re: OLE and Internet Explorer
Shawn Administrator Offline
Administrator
*****

Registered: 1999-08-13
Posts: 8611
Not too sure. Figure it's something to do with the COM/OLE support.

I've got a Win95 "gameboy" *grinz* at home just for playing Diablo II, I'll try some of this stuff tonight and report back tomorrow.

Shawn.


Top
#51313 - 2000-09-12 08:33 PM Re: OLE and Internet Explorer
Bryce Offline
KiX Supporter
*****

Registered: 2000-02-29
Posts: 3167
Loc: Houston TX
I have unshelved a win9x computer and hooked it back up and am currently looking into it too, this is what I have so far.

the command

code:

? olegetproperty($ie, "document")

is returning this.

?d

and

code:

? ("&" + olegetproperty($ie, "document"))

is returning this

&???D?D> ( and '>' = asc(16) )

Am I correct in guessing that this should be a hex number?

Bryce

COOL! we got this thread to go 2 pages

[This message has been edited by Bryce (edited 12 September 2000).]

Top
#51314 - 2000-09-12 09:19 PM Re: OLE and Internet Explorer
Shawn Administrator Offline
Administrator
*****

Registered: 1999-08-13
Posts: 8611
You testing Win95 or Win98 ?
Top
#51315 - 2000-09-12 10:09 PM Re: OLE and Internet Explorer
Bryce Offline
KiX Supporter
*****

Registered: 2000-02-29
Posts: 3167
Loc: Houston TX
win95
ie5

Top
#51316 - 2000-09-13 04:14 PM Re: OLE and Internet Explorer
Shawn Administrator Offline
Administrator
*****

Registered: 1999-08-13
Posts: 8611
Didn't get a chance to test last night.Drat.

But was wundrin if it has something to do with COM/OLE and 16/32 bit support. Me thinks it does.

The problem would seem to be something to do with the way KiX fetches or OLE delivers, virtual addresses through the IDispatch (Automation) interface ...

Could you run the following script on Win95.

code:

break on


$ie = olecreateobject("internetexplorer.application")
?"create: ie=$ie error=@error @serror"


$rs = olecallfunc($ie, "navigate", "s", "about:blank")
?"navigate: rs=$rs error=@error @serror"


$rs = oleputproperty($ie, "visible", "s", "-1")
?"visible: rs=$rs error=@error @serror"


?"hit any key to continue..." get $k ; the Radimus Special 'K'


while olegetproperty($ie, "busy") <> "0" and @error = 0 loop
?"loopbusy: error=@error @serror"


$doc = olegetproperty($ie, "document")
?"document: doc=$doc error=@error @serror"


$rs = olecallfunc ( $ie, "quit" )
$rs = olereleaseobject ( $ie )

exit


If this doesn't work - we can aslo look at writting the same script in VBScript to see if the same thing occurrs (eliminate KiX as the problem)...

Shawn.


Top
#51317 - 2000-09-13 04:46 PM Re: OLE and Internet Explorer
Bryce Offline
KiX Supporter
*****

Registered: 2000-02-29
Posts: 3167
Loc: Houston TX
ok i ran it and i got the following.

quote:

Win2k
U:\temp>kix32 test2

create: ie=1331388 error=0 The operation completed successfully.
navigate: rs= error=0 The operation completed successfully.
visible: rs=0 error=0 The operation completed successfully.
hit any key to continue...
loopbusy: error=0 The operation completed successfully.
document: doc=1456a4 error=0 The operation completed successfully.


Win95
U:\temp>kix32 test2

create: ie=4466612 error=0 The operation completed successfully.
navigate: rs= error=0 The operation completed successfully.
visible: rs=0 error=0 The operation completed successfully.
hit any key to continue...
loopbusy: error=0 The operation completed successfully.
document: doc=?V error=0 The operation completed successfully.



I also came up with a similar biy of code yesterday

code:

$false = 0
$true = -1

$ie = olecreateobject("internetexplorer.application")
? "$Ie <--- this is the handle for the IE exe that was just opened."
; Set properties and display form ...
$nul = oleputproperty($ie, "addressbar","s","$false")
$nul = oleputproperty($ie, "menubar", "s", "$false")
$nul = oleputproperty($ie, "toolbar", "s", "$false")
$nul = oleputproperty($ie, "statusbar", "s", "$false")
$nul = oleputproperty($ie, "resizable", "s", "$false")
$nul = oleputproperty($ie, "top", "s", "100")
$nul = oleputproperty($ie, "left", "s", "200")
$nul = oleputproperty($ie, "height", "s", "165")
$nul = oleputproperty($ie, "width", "s", "275")
$nul = oleputproperty($ie, "visible", "s", "$true")
$nul = olecallfunc($ie, "navigate", "s", "about:blank")

while olegetproperty($ie, "busy") <> "0" and @error = 0 loop

; Get a handle to the open document ...
; $doc = val("&" + olegetproperty($ie, "document"))

? olegetproperty($ie, "document") + " <--- this is the handle for the IE Document should be a hex#"
? @serror



Bryce

Top
#51318 - 2000-09-13 07:25 PM Re: OLE and Internet Explorer
Shawn Administrator Offline
Administrator
*****

Registered: 1999-08-13
Posts: 8611
Bryce...

Can you try this on Win95 ...

c:\> wscript test.vbs

or cscript.exe will work too !

code:

dim ie, doc


set ie = createobject ("internetexplorer.application")


ie.navigate ( "about:blank" )
ie.visible = 1


set doc = ie.document


doc.write ( "<html><body><h1>Hello Bryce!</h1></body></html>" )


msgbox ("Pausing...")


ie.quit()


set doc = nothing


set ie = nothing


Shawn

p.s.

I didn't code-up the wait for busy loop - hope it doesn't interfere !

Shawn..

p.p.s.

I'm hoping that this is a taste of what KiXtart2000 will be like ?

Shawn...

[This message has been edited by Shawn (edited 13 September 2000).]

Top
#51319 - 2000-09-13 07:31 PM Re: OLE and Internet Explorer
Bryce Offline
KiX Supporter
*****

Registered: 2000-02-29
Posts: 3167
Loc: Houston TX
I only did a minimal install of IE on my win9x box.

I have to go to traffic court now but I will give it a shot when i get back, in about an hour or so. Exactly what time zone are you in Shawn? ;D


Bryce (Central GMT -06:00)

Top
#51320 - 2000-09-13 07:37 PM Re: OLE and Internet Explorer
Shawn Administrator Offline
Administrator
*****

Registered: 1999-08-13
Posts: 8611
(GMT-05:00) Eastern Time (US & Canada)

I've got 1:33 pm

Got yourself into some Vehicular Scripting troubles did you ?

I think I ran over a Visual Basic dog the other day - backed-up over it just to make sure it was dead !

Shawn.

[This message has been edited by Shawn (edited 13 September 2000).]

Top
#51321 - 2000-09-13 11:16 PM Re: OLE and Internet Explorer
Bryce Offline
KiX Supporter
*****

Registered: 2000-02-29
Posts: 3167
Loc: Houston TX
Shawn ok i ran the vb script on my 95 computer. this is what i got

Script execution error on line 8, unspecified error.

line 8 = "set doc = ie.document"

Hmmmm...... I do belive that a bug has been found?

Bryce

Top
#51322 - 2000-09-13 11:31 PM Re: OLE and Internet Explorer
Shawn Administrator Offline
Administrator
*****

Registered: 1999-08-13
Posts: 8611
Bryce:

Ok - first try this script...

Give IE lots of time to "loadup" before continuing on the first pause. I would expect the same error.

code:

dim ie, doc


set ie = createobject ("internetexplorer.application")


ie.navigate ( "about:blank" )
ie.visible = 1


msgbox ("Pausing...")


set doc = ie.document


doc.write ( "<html><body><h1>Hello Bryce!</h1></body><html>" )


msgbox ("Pausing...")


ie.quit()


set doc = nothing


set ie = nothing


Then try this code...

code:

dim ie


set ie = createobject ("internetexplorer.application")


ie.navigate ( "about:blank" )
ie.visible = 1


msgbox ("Pausing...")


ie.document.write ( "<html><body><h1>Hello Bryce!</h1></body><html>" )


msgbox ("Pausing...")


ie.quit()


set doc = nothing


set ie = nothing


This bypasses the olegetproperty() type function and accesses the document object directly !

Shawn.

Top
#51323 - 2000-09-14 12:39 AM Re: OLE and Internet Explorer
Bryce Offline
KiX Supporter
*****

Registered: 2000-02-29
Posts: 3167
Loc: Houston TX
ok....both vb scripts worked..... no errors!

I found this fix also and was able to get your original vbs script to work.

code:

dim ie, doc
set ie = createobject ("internetexplorer.application")
ie.navigate ( "about:blank" )
ie.visible = 1


Do: Loop Until ie.ReadyState = 4


set doc = ie.document
doc.write ( "<html><body><h1>Hello Bryce!</h1></body><html>" )
msgbox ("Pausing...")
ie.quit()
set doc = nothing
set ie = nothing


So using this logic I also tried a long wait period in a kix script but instead of "?v" as a handle you get "?????" still not the hex number that is required

Bryce

Top
#51324 - 2000-09-15 04:57 PM Re: OLE and Internet Explorer
Bryce Offline
KiX Supporter
*****

Registered: 2000-02-29
Posts: 3167
Loc: Houston TX
A follow up to the olegetproperty() function on win9x.

It appears that this is a bug in kix and olegetproperty() will always fail, hopefully this will be fixed for the new version of kix.

Bryce

Top
Page 2 of 2 <12


Moderator:  Glenn Barnas, NTDOC, Arend_, Jochen, Radimus, Allen, ShaneEP, Ruud van Velsen, Mart 
Hop to:
Shout Box

Who's Online
0 registered and 640 anonymous users online.
Newest Members
ManuvdWielNL, Sir_Barrington, batdk82, StuTheCoder, M_Moore
17887 Registered Users

Generated in 0.071 seconds in which 0.027 seconds were spent on a total of 13 queries. Zlib compression enabled.

Search the board with:
superb Board Search
or try with google:
Google
Web kixtart.org