I'm hoping someone may be able to help.
Dropbox stores its path in a file called 'info.json'. The contents of my file is as follows:
{"personal": {"path": "C:\\Users\\Sam\\Dropbox", "host": 241656592}}
{"business": {"path": "C:\\Common\\Allusers\\Dropbox", "host": 45143292}}
I need to extract the 'personal' path only to a Windows CMD variable %dropboxpath% using only a windows batch script. I have tried using FOR and FINDSTR but couldn't make it work.
The other issue is stripping away the extra backslashes in the path to leave 'C:\Users\Sam\Dropbox'.
I believe FINDSTR should locate the 'personal' line and FOR should extract everything after "path": but before , "host" and then somehow, remove the double backslashes.
Hope this makes sense and really appreciate any help you could give.
Many thanks, Sam