Must you always call ImageInfo before SetNewValue when not testing for the existence or value of any tag?
Can I go straight to SetNewValue after creating a new Object without calling ImageInfo()?
my $exifTool = new Image::ExifTool; # Create a new exifTool Object
$Info = ImageInfo($File,\@TagList); # Open File and return tag list
# Set new values to Subject and HierarchicalSubject
$exifTool->SetNewValue(); # Clear previously queued values
$exifTool->SetNewValue('Subject' => $Subject);
$exifTool->SetNewValue('HierarchicalSubject' => $Subject);
# Write to file
my $Write = $exifTool->WriteInfo($File);
No, absolutely not. If you are just writing you shouldn't be calling ImageInfo().
- Phil
Thanks. :)