Search found 8 matches
- Thu Dec 03, 2020 12:25 pm
- Forum: Help Me
- Topic: PNGSaveOptions
- Replies: 1
- Views: 3801
PNGSaveOptions
I can't work out why this isn't saving an uncompressed PNG? Would be grateful of any suggestions! pngOpts = new PNGSaveOptions(); pngOpts.compression = 0; // 'false' also doesn't work pngOpts.interlaced = false; canvas.saveAs((new File(subF+'/'+basename)),pngOpts,false); The PNG options last used (m...
- Wed Dec 02, 2020 8:57 pm
- Forum: Help Me
- Topic: Search and Replace in a text file
- Replies: 4
- Views: 5918
Re: Search and Replace in a text file
Thanks! I just found that solution at the same time I read your reply.
- Wed Dec 02, 2020 12:39 pm
- Forum: Help Me
- Topic: Search and Replace in a text file
- Replies: 4
- Views: 5918
Re: Search and Replace in a text file
OK, well this works, but won't catch errors, and there's probably a simpler method: #target photoshop f = new File('C:/Users/Ian/Desktop/test.txt') f.open('r') var conts = f.read() f.close f.open('w') newConts = conts.replace(/oldtext/g, 'newtext') f.write(newConts) f.close But I now have a new and ...
- Tue Dec 01, 2020 9:21 pm
- Forum: Help Me
- Topic: Search and Replace in a text file
- Replies: 4
- Views: 5918
Search and Replace in a text file
OK not strictly PS related, but I'm doing it from a javascript PS script: So what's the simplest method to search and replace in a text file? I could do it, but in a clumsy way! I'm unclear whether I need to read the whole file, S+R, and then re-write the whole file. I'm thinking there may be a simp...
- Tue Dec 01, 2020 7:18 am
- Forum: Help Me
- Topic: Running an EXE *with arguments*
- Replies: 5
- Views: 5955
Re: Running an EXE *with arguments*
Nothing important, it was only one of the folder names in the argument
Thanks again for your help.

- Mon Nov 30, 2020 11:00 pm
- Forum: Help Me
- Topic: Running an EXE *with arguments*
- Replies: 5
- Views: 5955
Re: Running an EXE *with arguments*
Really weird, that was working, now doesn't seem to be....
****EDIT: Now it is (silly typo).
****EDIT: Now it is (silly typo).
- Mon Nov 30, 2020 10:36 pm
- Forum: Help Me
- Topic: Running an EXE *with arguments*
- Replies: 5
- Views: 5955
Re: Running an EXE *with arguments*
Perfect (nearly!), I had to use double backslashes (to Escape the backslash I think?). Using a variable for the argument, I ended up with: var arg = ' "C:\\Users\\Ian\\Desktop\\9 SP test tiles\\stitched\\SP.tfw"' system('start "" "C:\\Program Files\\MAPC2MAPC64\\mapc2mapc64....
- Mon Nov 30, 2020 10:14 pm
- Forum: Help Me
- Topic: Running an EXE *with arguments*
- Replies: 5
- Views: 5955
Running an EXE *with arguments*
I'm new to PS scripting, and really pleased with what I achieved over the weekend! Stitching a lot of map tiles together using parts of the filename to determine their position. But I am stuck on trying to run an EXE with arguments , from within a JSX. I can do it OK without arguments. Something suc...