get specific cell value in csv file using powershell
问题 I am new to powershell, don't get to use this often. I need to output the value of cell A5 from a csv file using powershell my file - col1 col2 col3 col4 ---- ---- ---- ---- 1002 1005 1006 1007 need value in the A1 cell i.e 1002.selection should be done by the cell numbers. $a = @(Import-CSV filepath.csv) $a[1].(col1) thanks in advance 回答1: Import the CSV to your variable $a = Import-CSV filepath.csv Then grab the first row $a[0] and use . notation to get the column you want. Note that the