I'd like to insert pictures at the end of each row (roughly column 'I') when I run the script. The beginning of the file names correspond to the aforementioned line numbers (e.g. "Line 20 - house.png"). All of the pictures are contained in one folder. So, basically, I believe the macro would need to search the folder for a partial file name, return the file name, and insert the picture in the corresponding cell.
I don't have any experience with this API, and it's been years since I've programmed things. The documentation isn't what I'm used to, so I'm finding it hard to find what I'm looking for.
Here's some laughably simple pseudocode (informal, obviously) that I think does what I'm looking for:
Code: Select all
for x, firstLine to lastLine
FileName = Search(path for "Line " + x)
InsertPhoto(FileName, Row[x]Column[I])
end