Sign in to follow this  
Followers 0
xroot

Simple Charts

17 posts in this topic

I needed a way to produce quick charts with simple data input.(for boss)

I created this wrapper dll around Microsoft Chart Control 6.0,

so if you have the (mschrt20.ocx) then this might work for you.

Very simple to use, the objects are: ".Title,.Legend,.SetData,.Row,.RowLabel,.Show" that's it.

The sample script will show how it's used, click the buttons to get either 2D Bar,2D Area,

2D Line, 2D Pie, 2D Stack, and 3d Bar.

chartcom.zip

Share this post


Link to post
Share on other sites



I am having a problem with $Chart.Title... My system says variable must be of type"Object"

Share this post


Link to post
Share on other sites

Hi

Well done :P

@gseller: U have to register the dll.

Put it in the System32 dir and then run "regsvr32 chartcom.dll"

Here is a quick screenshot:

Posted Image

Mfg Spider


www.AutoIt.de - Moderator of the German AutoIt Froum

Share this post


Link to post
Share on other sites

Where can i find help about this object ?

Thanks

Share this post


Link to post
Share on other sites

WOW! Nice effect! Thanks...

Share this post


Link to post
Share on other sites

Put it in the System32 dir and then run "regsvr32 chartcom.dll"

did that, still getting the title error :P


Share this post


Link to post
Share on other sites

Excellent work. :P

Now I can drop Excel (which I used for graphing

data from an SQL table) and use your wrapper instead.

Thank you! :unsure:

Share this post


Link to post
Share on other sites

#8 ·  Posted (edited)

It is not working in my vm machine where Office is not installed although I've registered the DLL.

I assume Office API is needed.

On my real machine where Office is installed it is working properly.

You just need the mschrt20.ocx file in system32 and of course the DLL registered then it will work! Unfortunately mschrt20.ocx is a part of the office package :P

UEZ

Edited by UEZ

Please don't send me any personal message and ask for support! I will not reply!

Selection of finest graphical examples at Codepen.io

The own fart smells best!
Her 'sikim hıyar' diyene bir avuç tuz alıp koşma!
¯\_(ツ)_/¯

Share this post


Link to post
Share on other sites

There *is* another way. Take a look here:

http://www.rmchart.com/rmc/downloads.htm

As far as I'm aware, RMChart is freeware and does some nice graphs! See here for an example. If anyone has the time then it would be nice to see an example using this ActiveX control. The main web site doesn't appear to generate a page (http://www.rmchart.com) but if you google for "site:www.rmchart.com" then you'll get plenty of hits.

WBD

Share this post


Link to post
Share on other sites

#11 ·  Posted (edited)

This is really a great DLL. There's even a non-COM one :P

Btw: The homepage can be found at http://www.rmchart.com/rmc/

//Edit: The mschrt20.ocx is not included in Office. It is included in VB 6. For me, this downlosd worked: DL Also, i had to change the regsvr to allow spaces in path:

Func OnAutoItStart()
    RunWait(@SystemDir&'\regsvr32 /s "'&@ScriptDir&'\ChartCom.dll"') ;Register DLL silent
;    RunWait(@SystemDir&'\regsvr32  "'&@ScriptDir&'\ChartCom.dll"') ;Register DLL
EndFunc

Func OnAutoItExit()
    RunWait(@SystemDir&'\regsvr32 /s /u "'&@ScriptDir&'\ChartCom.dll"') ;unRegister DLL silent
;    RunWait(@SystemDir&'\regsvr32 /u "'&@ScriptDir&'\ChartCom.dll"') ;unRegister DLL
EndFunc
Edited by ProgAndy

*GERMAN* [note: you are not allowed to remove author / modified info from my UDFs]My UDFs:[_SetImageBinaryToCtrl] [_TaskDialog] [AutoItObject] [Animated GIF (GDI+)] [ClipPut for Image] [FreeImage] [GDI32 UDFs] [GDIPlus Progressbar] [Hotkey-Selector] [Multiline Inputbox] [MySQL without ODBC] [RichEdit UDFs] [SpeechAPI Example] [WinHTTP]UDFs included in AutoIt: FTP_Ex (as FTPEx), _WinAPI_SetLayeredWindowAttributes

Share this post


Link to post
Share on other sites

#12 ·  Posted (edited)

Fortunately there's backups online in case your ocx file should get corrupted:

http://search.yahoo.com/search?p=mschrt20.ocx

The internet is full of software downloads but do you know the licenses agreement of mschrt20.ocx? Is it allowed to use standalone? etc....

I don't know!

Further I don't know from which software package mschrt20.ocx is! I assume from office but I'm not sure!

UEZ

Edited by UEZ

Please don't send me any personal message and ask for support! I will not reply!

Selection of finest graphical examples at Codepen.io

The own fart smells best!
Her 'sikim hıyar' diyene bir avuç tuz alıp koşma!
¯\_(ツ)_/¯

Share this post


Link to post
Share on other sites

There *is* another way. Take a look here:

http://www.rmchart.com/rmc/downloads.htm

As far as I'm aware, RMChart is freeware and does some nice graphs! See here for an example. If anyone has the time then it would be nice to see an example using this ActiveX control. The main web site doesn't appear to generate a page (http://www.rmchart.com) but if you google for "site:www.rmchart.com" then you'll get plenty of hits.

WBD

Maybe somebody has enough time to write an UDF for rmchart DLL :P

UEZ


Please don't send me any personal message and ask for support! I will not reply!

Selection of finest graphical examples at Codepen.io

The own fart smells best!
Her 'sikim hıyar' diyene bir avuç tuz alıp koşma!
¯\_(ツ)_/¯

Share this post


Link to post
Share on other sites

This MsCharts DLL works very well. Thanks for posting it. I am a COM/DLL newbie (well all around newbie for that matter). I did manage to look at the com methods for this object and thought that it would be great if EditCopy were available (it does not seem to be part of the DLL which is why I think I cannot access it ... is that right?). I am trying to paste the image created with the DLL call back into excel since it is easier than creating excel charts. Is there a way to do that short of adding EditCopy to the DLL?


Build your own poker game with AutoIt: pokerlogic.au3 | Learn To Program Using FREE Tools with AutoIt

Share this post


Link to post
Share on other sites

Is any documentation online about mschrt20.ocx?


When the words fail... music speaks

Share this post


Link to post
Share on other sites

Is there any way to force one particular chart type and not show the buttons to switch between them?

Share this post


Link to post
Share on other sites

Is there any way to force one particular chart type and not show the buttons to switch between them?

Yes, let me take a look and see what I can do.

Thanks

Share this post


Link to post
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
Sign in to follow this  
Followers 0