Can one use VBA to create a new chart type in PowerPoint? - vba

I don't believe this is possible, but I would love to have confirmation from PowerPoint VBA experts.
I am trying to make a chart in PowerPoint that is essentially a bar graph whose bars have a variable width (i.e. the width of each bar is an input into the chart, as opposed to your classic bar chart, which has a set width for each bar). This is of course not possible in PowerPoint as there is no such chart type for this.
Is it possible to use VBA code to create something like this? I have a hunch that it is not and that I am limited to interacting with the PowerPoint library and the set chart types.
Any insight into this will be greatly appreciated. I am struggling to think of a solution for displaying my data in this particular manner.

Something like the chart in this tutorial: Variable Width Column Charts (Cascade Charts)? It's probably easier to do in Excel, because the data isn't a layer further removed from the chart, but you could follow the same protocol in PowerPoint. This is a manual protocol; I've written VBA to do it in Excel, and I'm going to do the same for PowerPoint when I get a chance.

Related

PoiwerPoint auto-updating text boxes

I want to know if there is a way to link text boxes in PowerPoint in a similar fashion as Excel so that when I update one text box (for instance, changing the title of the presentation), the other linked text boxes will update by themselves. The purpose is to avoid having to go through the whole presentation to change manually every relevant slides. I don't think there is a build in function but I am fairly new to VBA in PowerPoint (have some experience with Excel already). Any input is very much appreciated, thank you!

Formatted Text (Word Art style) Dynamically Updated in PowerPoint 2010?

I am working on developing weather graphics in PowerPoint 2010 for our online weather forecast operation. I am trying to update formatted text (Word Art type formatting, such as text outlining, shadowing, etc.,) automatically within a PowerPoint slide.
Click for example map
I have looked through the numerous articles both here and elsewhere on how to dynamically update text from Excel cells in PowerPoint and other methods, but I can't find any way of updating text such as the temperature values in the map above, while still keeping the visual formatting (which is absolutely crucial for this project). Is there any way to do this in text format, or would I just be better off developing the system so that the text values on the map are actually auto-updating images, so that the formatting is preserved? If that is the route I must take, I am fine with that. I just need pointed in the right direction. Any help would be tremendously appreciated.
Thank you for your time...

How do I use Excel to insert blocks into AutoCAD drawings?

I'm trying to use Excel to create AutoCAD drawings. I have a list of product numbers and I'd like to use VBA so that upon hitting a button it will find a block or a drawing file of every product on the list and paste them into an AutoCAD drawing (to a specific point would be a bonus).
So far I've found code that will read from two columns in Excel and will plot a polyline in ACAD using those columns as coordinates. It's very simple but not exactly what I want. Does anyone have suggestions or example code that does something similar? I've found some online using the "ThisDrawing." object but Excel isn't recognizing that so I've reached a stand still. I have all day tomorrow to work on it, so I'll be doing a lot more searching, but any help is definitely appreciated. Thank you
Autodesk provide free downloads on their website so that you can add the VBA IDE into AutoCAD.
Then, inside the AutoCAD IDE you start a new VBA project.
Add a reference to your Excel library so that you can read the Excel spreadsheet.
You need to look up on:
ThisDrawing.ModelSpace.InsertBlock
In the AutoCAD VBA manual. It tells you what various parameters. But they are straightforward - origin, scale, rotation, path to block.
When you call the InsertBlock routine it will create a AcadBlockReference object. You can do any further customization on that object.

Would it be possible to subclass a Chart in VBA?

Would it be possible to "subclass" a Chart in Excel to create a modified version of it?
My wish is for an Improved Bubble/XY Chart in Excel. With the native chart, I can create charts of varying X, Y and Bubble Size, such as:
In a recent project, I wanted to classify these bubbles into groups A and B based on some given criteria, and using different colors was the solution I found. I also wanted to label each bubble on a per-row basis. I had to use a simple VBA Macro to color the bubbles and add labels dynamically, but the end result was quite nice:
In the end, I was left wondering. My programming experience is mostly in Python, so naturally I though of subclassing the regular Chart to allow for a more user friendly experience, such as customizable colors, categories and being able to pick labels from a Range. Is that possible in VBA?
Most of the tips for VBA subclassing that I have found online refer to using the Windows API and subclassing UserForms, but that is not exactly what I want.

Powerpoint 2007 break links on the datasheet of an embedded chart object

I would like to break the links in the datasheet of an embedded chart object .
This code updates the links, but I need the links broken.
Thanks
pptWorkbook.UpdateLink pptWorkbook.LinkSources(1)
PS. How do you update multiple link sources without and error message.?
I think I solved this once by simply assigning a vbnullstring or "" as link, which then appears in the link dialog as NULL (so I am taking about charts pasted from Excel it this is what you mean by embedded chart; because your question makes no sense if you mean a 'native' ppt2007+ chart object)
Ungroup the shape that represents the chart. That breaks the link, converts the chart into a vector (ie, EMF/WMF) graphic.