Jump to content

OBJ Help


Recommended Posts

I'm using the following ActiveX Component: http://www.codeproject.com/KB/atl/SmartGra...amp;fr=26#xx0xx

#include <GUIConstantsEx.au3>
#Include <IE.au3>

$Form1 = GUICreate("", 163, 58, 193, 115)
$Progress1 = GUICtrlCreateProgress(8, 8, 150, 17)
GUICtrlSetData(-1, 25)
$Progress2 = GUICtrlCreateProgress(8, 32, 150, 17)
GUICtrlSetData(-1, 25)
GUISetState(@SW_SHOW)
#EndRegion ### END Koda GUI section ###

$oGraph = ObjCreate ("Graph.SmartGraph.1")
$oGraph.SetParentWnd($Form1)
$oGraph.SetPlotType(0);Regular Graph
$oGraph.put_xLable("Time")
$oGraph.put_yLable("Amplitude")
$oGraph.put_Title("Graph Test")


While 1
    $nMsg = GUIGetMsg()
    Switch $nMsg
        Case $GUI_EVENT_CLOSE
            Exit
    EndSwitch
WEnd

Really not sure what's going wrong....

The requested action with this object has failed.:

$oGraph.SetParentWnd($Form1)

$oGraph.SetParentWnd($Form1)^ ERROR

Could anyone point me in the right direction?

The object was created ok though.

Edited by BrettF
Link to comment
Share on other sites

I suppose you have correctly registered the dll (regsvr32 SmartGraph.dll)...

I tried with VBA and it doesn't work. I Got the same error

If you take a look at the FAQ, you could see this :

I've contacted the author and it seems not to work in VB. This graph component needs some pointers which is not supported by VB. My suggestion was to make it an OCX to overcome this problem perhaps. Unfortunately, I did not receive his opinion about this.

maybe there is a pb. It seems impossible to attach this activex to a form handle...

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...