Reply to topic  [ 3 posts ] 
Save As (and Save To) error 
Author Message

Joined: 2009-02-17 17:44:12
Posts: 37
I made the simple macro, which make a new document from selected text on the now editing document.

Code:
$doc1 = Document.active
$text = Read Selection
$doc2 = $doc1.copy
Menu ':Edit:Select:Select All'
Menu ':Edit:Delete'
Select Document End
$doc2.insertText( $text, 'm' )
Save As

### end of macro ###


When I run this macro and saved the new file, always the error dialogue come as "Could not save the file"; however, the file is saved.
Is there anyone can solve this problem?
I'm using NWP 2.0.1 on macosx 10.6.8

Kosaka


2011-11-10 17:29:34
Profile
Official Nisus Person
User avatar

Joined: 2002-07-11 17:14:10
Posts: 4251
Location: San Diego, CA
That "could not save" message should not be displayed, sorry about that. I think what's going wrong is that the "Save As" command is expecting you to give it a destination path and not handling the save dialog properly.

Luckily there is a workaround. Instead of using the built-in Save As command, you can activate the menu directly, eg:
Code:
Menu "Save As"


2011-11-11 00:58:55
Profile WWW

Joined: 2009-02-17 17:44:12
Posts: 37
Thank you, martin.

That's it!
Menu "Save As" works for my macro.

Quote:
That "could not save" message should not be displayed, sorry about that. I think what's going wrong is that the "Save As" command is expecting you to give it a destination path and not handling the save dialog properly.

I remember this point.

Anyway, I appreciate your kindly support.

Kosaka


2011-11-13 22:36:09
Profile
Display posts from previous:  Sort by  
Reply to topic   [ 3 posts ] 

Who is online

Users browsing this forum: No registered users and 4 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB® Forum Software © phpBB Group
Designed by ST Software