Charts and Addins

A

Andy

Hi All
I have an addin, which I will issue to users, that converts a load of data
into various charts and tables. Currently, the user specifies the chart
types to use (the list is taken from the XLUSRGAL workbook) but this involves
adding a user-defined chart to each machine. Is there a method by which I
can 'add' a chart type to the addin which can be used instead of those in the
XLUSRGAL?

This is for Excel 2002.

Thanks
Andy
 
P

Peter T

Hi Andy,

Just a thought - store a dummy chart as your custom type in your addin. In
the addin install event add to user's XLUSRGAL.

Periodically you could check if it still exists in the user gallery by
applying back to your dummy chart. Get and adapt code from the macro
recorder. Plenty of error handling though for all scenarios, including the
rare possibility of XLUSRGAL not being available.

Assumes you are distributing an addin rather than one on a network.

You can also copy paste chart formats, but there can be problems doing that
in some situations.

Regards,
Peter T
 
A

Andy

Hi Peter

This is probably a really stupid question but I don't seem to be able to get
the workbook that makes up my addin to appear on screen for me to add the
dummy chart to. How do I do this?
Thanks
Andy
 
B

Bob Phillips

In the VBE, select the add-in project. There is a property in project called
IsAddin, set that to False, and reset when done.

--

HTH

RP
(remove nothere from the email address if mailing direct)
 
P

Peter T

Select the ThisWorkbook module of your addin and in properties (F4) change
the IsAddin setting from True to False (reset when done).

I would add a chart sheet, ensure it has at least the minimum number of
series, and if necessary categories, for your chart type. For values just
enter ={1} in series source data for single point. If more points are needed
say =(1,1,1)

Before doing all this in your addin, why not get everything working with
code tested in a normal workbook and simulate the addin install event in a
normal macro.

Regards,
Peter T
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top