I'm saving .png files from Photoshop and I would like to write some informations in those files that could then be read in another program.
So far I've been using the names of the files to do this but it's getting to a point where there's too many naming conventions and so I would rather try to find a way to write that information somewhere in the .png itself.
Is this something that can be done with Photoshop scripting?
I presume that you mean metadata… but what metadata? Can you describe in more detail what information you would like to embed in a PNG image?
Metadata can be applied via various methods, with simple automation using actions and more complex automation using scripts. You can manually apply metadata, manually apply metadata templates and use Adobe Bridge to apply metadata in one or more images.
Keep in mind that various software reading your PNG files may or may not understand metadata and that some software may remove metadata.