OCGV: Out-ConsoleGridView does not accept XML data
See original GitHub issueWhile manipulating XML data and testing Out-ConsoleGridView
(Powershell 7.0.0 on Windows 10.0.19603), I noticed that the cmdlet appears to demand data of a certain datatype. For testing, a sample XML file can be found here.
[xml]$xml = Get-Content '.\sample.xml'
Tabular output from $xml
can be viewed in the terminal
$xml.catalog.book
Output
id : bk101
author : Gambardella, Matthew
title : XML Developer's Guide
genre : Computer
price : 44.95
publish_date : 2000-10-01
description : An in-depth look at creating applications
with XML.
id : bk102
...
Piping to Out-GridView
produces expected output
$xml.catalog.book | Out-GridView
However, piping to Out-ConsoleGridView
produces an error
$xml.catalog.book | Out-ConsoleGridView
The
BaseType
of $xml.catalog.book
is System.Array
Issue Analytics
- State:
- Created 3 years ago
- Reactions:1
- Comments:10 (4 by maintainers)
Top Results From Across the Web
PowerShell 7 ConsoleGridView
Let's have some fun and learn about the PowerShell 7 command Out-ConsoleGridView. All the benefits of Out-Gridview but in a console setting.
Read more >Extract XML data and Save as XML file - powershell
I'm using Invoke-WebRequest to save the file using -Outfile , but I don't want all the soap envelope data. From the sample data...
Read more >Can't open file that contains custom XML elements which ...
Describes an issue in which a particular custom XML markup implementation is removed in Word 2007, Word 2010 and Word 2013.
Read more >Work With XML Data in PowerShell - YouTube
Your browser can't play this video. Learn more.
Read more >Unable to publish XML data to printer using PowerShell
This script works for HP, just not Xerox. No errors are returned, and I am able to publish the XML if I manually...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
gentle ping on this
@andschwa please prefix title with "OCGV: ".