I eventually would like to utilize Word in an ActiveX container in Fivewin. I am trying to start by utilizing the Webexp.prg to learn (per Antonio post). I cannot get this to run. I also cannot find anything about TActiveX in the manuals under "A", or "T". Do I need a special library to be linked in to get this example to work?
Error I get:
Error description: Error BASE/1081 Argument error: +
Args:
[ 1] = O Object
[ 2] = N 200
Stack Calls
===========
Called from: TActiveX.prg => TACTIVEX:NEW(0)
Called from: TActiveX.prg => CREATEACTIVEX(184)
Called from: TActiveX.prg => TACTIVEX:NEW(0)
Called from: webexp.prg => MAIN(10)
Thanks,
ActiveX
-
- Posts: 254
- Joined: Sun Nov 06, 2005 3:55 pm
- Location: Southern California, USA
- Contact:
ActiveX
Thanks,
Byron Hopp
Matrix Computer Services
Byron Hopp
Matrix Computer Services
Friend,
This is a sample with Activex class?
And here the OLE class:
Try and report.
This is a sample with Activex class?
Code: Select all
#include "FiveWin.ch"
function Main()
local oWnd, oActiveX
local cEvents := ""
DEFINE WINDOW oWnd TITLE "FiveWin ActiveX Support"
oActiveX = TActiveX():New( oWnd, "Shell.Explorer.2" )
oActiveX:Do( "ToolBar" , "true" )
oActiveX:Do( "StatusBar", "true" )
oActiveX:Do( "MenuBar" , .T. )
oActiveX:Do( "Visible" , .T. )
oWnd:oClient = oActiveX // To fill the entire window surface
oActiveX:Do( "Navigate", "http://www.google.com" )
ACTIVATE WINDOW oWnd
return nil
Code: Select all
#include "FiveWin.ch"
function Main()
local oWnd, oIE
local cEvents := ""
DEFINE WINDOW oWnd TITLE "Internet Test"
oIE:=TOleAuto():New( "InternetExplorer.Application" )
oIE:ToolBar := .T.
oIE:StatusBar := .T.
oIE:MenuBar := .F.
oIE:Visible := .T.
oWnd:oClient = oIE // To fill the entire window surface
oIE:Navigate( "http://www.google.com" )
oIE:End()
ACTIVATE WINDOW oWnd
return nil
- Enrico Maria Giordano
- Posts: 7355
- Joined: Thu Oct 06, 2005 8:17 pm
- Location: Roma - Italia
- Contact:
They are both based on OLE technology but ActiveX is a control working like any other controls.anserkk wrote:Hi,
What is the difference between TOle class and TActivex class. In the above given example both the classes are doin the same. Where to use what ?.
May be it is a very silly question. Would like to know the difference
Regards
Anser
EMG
-
- Posts: 254
- Joined: Sun Nov 06, 2005 3:55 pm
- Location: Southern California, USA
- Contact:
ActiveX
Neither one works, the standard ole (the second one) does manage to launch Internet Explorer, but the window title is "Google - Windows Internet Explorer" which I believe is not in the Windows Container planned for in the code. I have gotten OLE to work very well with Excel so I am famialiar with controlling another application. I like to make sure the application is within a window I have created by the application. Is there any special libs I need to utilize. Is the only problem the way I call the application in the TActiveX new method (the program ID)? The activeX seems to be dying there.
Thanks,
Thanks,
Thanks,
Byron Hopp
Matrix Computer Services
Byron Hopp
Matrix Computer Services
- Antonio Linares
- Site Admin
- Posts: 37481
- Joined: Thu Oct 06, 2005 5:47 pm
- Location: Spain
- Contact: