Sorry,
needed to add the following lines which i worked out by looking at vb versions of the same thing and also using the get-member cmdlet.
$dl = $series.DataLabelsCollection.Add()
$dl.HasPercentage = "True
Solved....
$wordrunning = (Get-Process 'WinWord' -ea SilentlyContinue)
if ( $wordrunning -eq ""){
Write-Host "Please close all instances of Microsoft Word."
exit
}
else
{
}
Im trying to check if a process is running but get an error when checking which i dont want the users of my script to see, anyone know how i do this correctly ?
if ((Get-Process 'WinWord') -eq $False){
Write-Host "Please close all instances of Microsoft Word before running this report."
exit
}...
Hi,
I have managed to add a piechart to a word document using the following code, but I cant manage to get the pie chart to have percentage values, this is available using the .HasPercentage = True value but I cant get it right, can anyone help ?
Thanks
$msWord = New-Object -Com...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.