var sidebar_align = 'right';
var content_container_margin = parseInt('290px');
var sidebar_width = parseInt('270px');
Unanswered: How to format cells via VBScript code?
I'm trying desperately to find out how to change the formatting of Excel cells via VBScript code... set the alignment, font color, things like that.
I've spent a good hour on Google and MSDN library, no luck. Help!
Try the Macro Recorder!
You'll be amazed what that'll produce...
Hope that helps,
Cells.Select ' Bad Smitty - Don't Select unless you have to...
.NumberFormat = "$#,##0_);[Red]($#,##0)"
.HorizontalAlignment = xlRight
.VerticalAlignment = xlCenter
.WrapText = False
.Orientation = 0
.AddIndent = False
.ShrinkToFit = False
.MergeCells = False
.RowHeight = 17.5
.ColumnWidth = 12.5
With a bit of editing of course...
I actually found another solution which is easier.. just define styles in the Excel sheet, and then do this to set them:
Worksheets("blah").Range("A10").Style = "ThisStyle"