![]() |
![]() | ![]() | ![]() | ![]() | ![]() | ![]() | ![]() |
| Welcome to Windows Vista Forums. Our forum is dedicated to helping you find solutions with any problems, errors or issues you are experiencing with Windows Vista. The Vista forum also covers news and updates and has an extensive Windows Vista tutorial section that covers a wide range of tips and tricks. |
| |||||||
![]() |
| |
| | #1 (permalink) |
| Guest | Import-CSV from Web/Variable At the moment, the import-csv command only allows for importing a local CSV file (at least to my knowledge). However, I need to be able to pull a file off the web (using a System.Net.WebClient object) and then import that data straight into PS. I've tried passing data into a variable first and using "variable = [csv]data" (the latter turned out to only work for XML). Is there any sort of advanced method I'm missing out on or is this just impossible at the moment? |
My System Specs![]() |
| | #2 (permalink) |
| Guest | Re: Import-CSV from Web/Variable Luke wrote: > At the moment, the import-csv command only allows for importing a local CSV > file (at least to my knowledge). However, I need to be able to pull a file > off the web (using a System.Net.WebClient object) and then import that data > straight into PS. I've tried passing data into a variable first and using > "variable = [csv]data" (the latter turned out to only work for XML). Is there > any sort of advanced method I'm missing out on or is this just impossible at > the moment? Check this out as an example: http://powergadgets.com/csPg/forums/thread/185.aspx Marco |
My System Specs![]() |
| | #3 (permalink) |
| Guest | Re: Import-CSV from Web/Variable Thanks! I've thought of using a temporary file previously but didn't want to bother with generating a temp file name myself, but the "[System.IO.Path]::GetTempFileName()" method's much better. "Marco Shaw" wrote: > Luke wrote: > > At the moment, the import-csv command only allows for importing a local CSV > > file (at least to my knowledge). However, I need to be able to pull a file > > off the web (using a System.Net.WebClient object) and then import that data > > straight into PS. I've tried passing data into a variable first and using > > "variable = [csv]data" (the latter turned out to only work for XML). Is there > > any sort of advanced method I'm missing out on or is this just impossible at > > the moment? > > Check this out as an example: > http://powergadgets.com/csPg/forums/thread/185.aspx > > Marco > |
My System Specs![]() |
![]() |
| Thread Tools | |
| |
Similar Threads | ||||
| Thread | Forum | |||
| How to import variable values? | PowerShell | |||
| $Variable Is In {1,2,3,4} | PowerShell | |||
| Set-Variable | PowerShell | |||
| tab and variable | PowerShell | |||
| How can I ensure that a variable is a built-in powershell variable? | PowerShell | |||