I want to get the price of an item which is market in steam. I tried to use this formula but it is not working it tells me that the value is too big. and I did not know what to do. I want to get the price of an item which is on market on steam.
Blockquote =VALUE(REGEXEXTRACT(REGEXEXTRACT(CONCATENATE(IMPORTXML("https://steamcommunity.com/market/listings/730/Clutch Case", "//script[2]")),".*]]"), "[0-9] .[0-9] "))
CodePudding user response:
The main problem here is that the prices in the Steam page are generated by Javascript and IMPORTXML
cannot retrieve dynamically generated data. It seems that you're trying to get around this by importing a <script>
section, but this will not execute the script, you're just grabbing a bunch of code.
Edit: As mentioned in the answer I linked, you can test the currency
parameter in the URL with different numbers to get other currencies. In your case you can try currency=2
for pounds (£). You'll also have to edit the REGEXEXTRACT
to account for this change:
URL: http://steamcommunity.com/market/priceoverview/?currency=2&appid=730&market_hash_name=Clutch Case
Formula: =REGEXEXTRACT(JOIN("", IMPORTDATA(A1)), "median_price:""(£[0-9] .[0-9] )")