$url = 'https://www.nikkei.com/markets/kabu/' $html = (Invoke-Webrequest $url).ParsedHTML $nikkei = $html.getElementsByTagName("span") | Where-Object { $_.className -eq 'mkc-stock_prices' } | ForEach-Object { $_.innerText } Write-Host $nikkei
$url = 'https://www.nikkei.com/markets/kabu/' $html = (Invoke-Webrequest $url).ParsedHTML $nikkei = $html.getElementsByTagName("span") | Where-Object { $_.className -eq 'mkc-stock_prices' } | ForEach-Object { $_.innerText } Write-Host $nikkei