Jaymond Flurrie
Well-known Member
- Joined
- Sep 22, 2008
- Messages
- 921
- Office Version
- 365
- Platform
- Windows
I thought to resize my chart by VBA code so I recorded the process. The result was that it gave me percentages of the original. Then I decided to try using size from format chart area - it shows centimeters. Much better. Now I wanted to input it in VBA and it seems like VBA wants points, not centimeters. I just read from Word VBA book, that at least Word 2007 supports function "centimeterstopoints" which should actually be really simple division function - input centimeters, get points as the result. I tried that in Excel 2010 VBA immediate window with a very simple ?centimeterstopoints(10) command It should return 283.5 as the answer. What it actually returned? "Run-time error '429': ActiveX component can't create object"
Now sure, I can continue just by using a magic number of 28.35 in my code, but I'd be interested to know why the result is an error.
Now sure, I can continue just by using a magic number of 28.35 in my code, but I'd be interested to know why the result is an error.