Go Back   RetouchPRO > Tools > Software > Photoshop Scripting
Register Blogs FAQ Site Nav Search Today's Posts Mark Forums Read

Photoshop Scripting Learning and sharing for all platforms

path problems

Thread Tools
Old 09-28-2004, 09:47 AM
WickeD WickeD is offline
Junior Member
Join Date: Sep 2004
Posts: 1
path problems

Hello guys and girls,

I started scripting in photoshop with javascript a little while ago. I am currently making a script that automatically saves a copy of a psd as a resized TGA file in a user specified location. To get the file path and name I use a file browser box.

saveFile = File.openDialog("Select a file", "Bitmaps: *.tga");

Now, to make it easier for the user, I want the selected path to be saved with the psd file, so the next time the user wants to save that file, he doesn't have to fill in the path again. To do this, I would like to save

saveFile.absoluteURI (this contains the path as a string)

This works fine for short paths without spaces (eg. c:\test\test.tga).
But when the user selects a path that does contain spaces (eg.
c:\program files\test.tga), the string in saveFile.absoluteURI reads "/c/program%20files/test.tga" and when the path gets a little longer (eg. c:\documents and settings\my name\my documents\test.tga) saveFile.absoluteURI reads "~my%20documents\test.tga" instead of the whole path.

Does anyone know how to get around this problem?
Reply With Quote top

  RetouchPRO > Tools > Software > Photoshop Scripting

Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Removing Background cybersip Photo Retouching 24 04-14-2010 02:49 PM
Color Problems imann08 Photo Retouching 24 03-10-2007 08:43 AM
Can't Stroke Path bestremera Photoshop Help 2 05-20-2006 08:28 AM
Skin problems, undefined... pure Photo Retouching 43 03-02-2006 04:01 PM
Two problems Mark Adams Image Help 23 05-22-2005 12:47 PM

All times are GMT -6. The time now is 10:10 AM.

Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.
Copyright © 2016 Doug Nelson. All Rights Reserved