Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $filepath = "C:/test.xlsm"
- Write-Host "file : " $filepath
- [System.Threading.Thread]::CurrentThread.CurrentCulture = [System.Globalization.CultureInfo] "en-US"
- $Excel = New-Object -ComObject excel.application
- $Excel.visible = $false
- $Workbook = $excel.Workbooks.open($filepath)
- $Worksheet = $Workbook.WorkSheets.item("Feuil1")
- $Worksheet.activate()
- $cell= $worksheet.Cells.Item(2,1).Value()
- # End of program, we close Excel
- $workbook.Close()
- $excel.Quit()
- write-host $cell
- Read-Host
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement