Change font size on axis for excel chart with powershell -
i want change font size axis values 11 9 on chart:
the chart whole worksheet & have tried run macro tool , replicate in there change font size. vba:
activechart.axes(xlvalue).select selection.format.textframe2.textrange.font .baselineoffset = 0 .size = 11 end
i unable reproduce in powershell. have tried:
$excel = new-object -comobject excel.application $ws = $excel.workbooks.open('file.xlsx').sheets('chart') $ws.axes().item(1).format.textframe2.textrange.font.size = 11 $ws.axes().item(2).format.textframe2.textrange.font.size = 11
but textframe2 object isn't initialized. i'm pretty stuck on how proceed.
thanks
Comments
Post a Comment