You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I get warnings from Export-Excel when my query returns zero rows. I do not get these when not setting Title.
WARNING: Failed adding autofilter to worksheet 'worksheetnamehere': The property 'AutoFilter' cannot be found on this object. Verify that the property exists and can be set.
WARNING: Failed autosizing column of worksheet 'worksheetnamehere': You cannot call a method on a null-valued expression.
Row three, i.e. the row after the imported table's column names, become bold. This is not expected behaviour. Without a Title, the column names become bold and that is also what I would expect here.
Despite the above, AutoFilter, AutoSize, FreezeTopRow and Style seem to work perfectly.
Reproducible example of points 2 and 3, not needing SQL:
I'm trying to export SQL results to Excel spreadsheets with nice titles. My final goal is something lovely like
This almost works. However,
Export-Excel
when my query returns zero rows. I do not get these when not settingTitle
.Title
, the column names become bold and that is also what I would expect here.AutoFilter
,AutoSize
,FreezeTopRow
andStyle
seem to work perfectly.Reproducible example of points 2 and 3, not needing SQL:
To replicate point 1, delete all of
$data
except for the column list.The text was updated successfully, but these errors were encountered: