Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations biv343 on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Transfering VB example to VFP Code For ChartFX 98

Status
Not open for further replies.

ontsjc

Technical User
May 17, 2000
113
I'm using ChartFX 98 to create some graphs and wish to use it's annotation extension. The problem is that all examples are in Visual Basic and I'm having trouble converting between the two. How do I translate the following visual basic example into something that I can understand. I haven't done alot of this and always seem to get lost along the way.

AnnotX= ChartFX1.AddExtension "AnnotationX.AnnList"

Dim r As AnnText
Set r = AnnotX.Add(OBJECT_TYPE_TEXT)
r.Text = "My Label"
r.Top = 50
r.Left = 50

Thanks for any help anyone can give me.
 
Hi!

VFP code:

#DEFINE OBJECT_TYPE_TEXT ????
AnnotX = ChartFX1.AddExtension("AnnotationX.AnnList")

local r
r = AnnotX.Add(OBJECT_TYPE_TEXT)
r.Text = "My Label"
r.Top = 50
r.Left = 50

You require to find the value of OBJECT_TYPE_TEXT constant somwhere in the help or get it from the TLB/OCX file using some tools. In addition, if you have VB, you can try to run the code that displays this constant value in the message box.

Vlad Grynchyshyn
vgryn@softserve.lviv.ua
The professional level of programmer could be determined by level of stupidity of his/her bugs
 
Hey Thanks for the repy. I appreciate it. I think the problem must be the OBJECT_TYPE_TEXT variable. The help memu doesn't have any other value for it. Since I'm new at this, what tools would be useful for getting this value from the TLB/OCX file? Class browser seems useless here and I don't have visual basic that I know of. Thanks again.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top