ExifTool Forum

ExifTool => Newbies => Topic started by: jesuschristhimself on April 14, 2023, 07:13:06 PM

Title: Finding the gps location on an image
Post by: jesuschristhimself on April 14, 2023, 07:13:06 PM
whenever i hit enter on my code in the powershell, it just says "," thats it nothing else
idk why but if someone can help

exiftool.exe '.\me 2.jpg' -n  -p "$GPSLatitude,$GPSLongitude"

Title: Re: Finding the gps location on an image
Post by: StarGeek on April 14, 2023, 09:02:58 PM
Pay attention to the highlighting when using Powershell.  If you look carefully at your command, you will see that "$GPSLatitude" and "$GPSLongitude" are highlighted differently than the rest of the command.  That highlighting indicates that these are being treated as Powershell variables, not exiftool tag names.

Use single quotes around any parameter with a dollar sign in it.  Or use CMD, as there are other idiosyncrasies that PS has which you have to account for.

Edit:  Your sample image doesn't have any GPS tags anyway, so you're going to get a tag not defined warning.