Xojo Conferences
MBSSep2018MunichDE
XDCMay2019MiamiUSA

Save Dialog Box (Real Studio network user group Mailinglist archive)

Back to the thread list
Previous thread: Read Only
Next thread: Importing Old (RB 2 era) classes/projects... Any ideas?


Reading *CSV Files versus *.Txt Files   -   Claude Stone
  Save Dialog Box   -   Sven E Olsson
   Re: Save Dialog Box   -   Joe Strout
   Re: Save Dialog Box   -   Arnaud Nicolet
   Re: Save Dialog Box   -   Sven E Olsson
    Re: Save Dialog Box   -   Joe Strout
   Re: Save Dialog Box   -   Sven E Olsson

Save Dialog Box
Date: 26.01.09 18:25 (Mon, 26 Jan 2009 18:25:17 +0100)
From: Sven E Olsson
Hi list, On OS X in TextWrangler it is easy to change a file extension
when doing Save As...
But using the RB Save Dialog... then it begins to change the "Hide
Extension" check-box .. and the result is that the extension can't be
changed.. The result from an html ( extension .html ) file would be
like this: index.php.html

Any ideas on this thing?

Regards from Sweden,
Sven E

_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>

Search the archives:
<http://support.realsoftware.com/listarchives/lists.html>

Re: Save Dialog Box
Date: 26.01.09 18:57 (Mon, 26 Jan 2009 10:57:34 -0700)
From: Joe Strout
Sven E Olsson wrote:

> Hi list, On OS X in TextWrangler it is easy to change a file extension
> when doing Save As...
> But using the RB Save Dialog... then it begins to change the "Hide
> Extension" check-box .. and the result is that the extension can't be
> changed.. The result from an html ( extension .html ) file would be like
> this: index.php.html

That's normal Mac behavior. If TextWrangler somehow manages to avoid
it, it must be doing some really crazy stuff (or, it's just not
supplying an extension on the suggested file name).

Best,
- Joe

Re: Save Dialog Box
Date: 26.01.09 19:08 (Mon, 26 Jan 2009 19:08:32 +0100)
From: Arnaud Nicolet
Le 26 janv. 09 à 18:57 (soir), Joe Strout a écrit:

> Sven E Olsson wrote:
>
>> Hi list, On OS X in TextWrangler it is easy to change a file
>> extension when doing Save As...
>> But using the RB Save Dialog... then it begins to change the "Hide
>> Extension" check-box .. and the result is that the extension can't
>> be changed.. The result from an html ( extension .html ) file would
>> be like this: index.php.html
>
> That's normal Mac behavior. If TextWrangler somehow manages to
> avoid it, it must be doing some really crazy stuff (or, it's just
> not supplying an extension on the suggested file name).

No, I think this behavior can be changed using some special flags (not
directly available to RB unless using the MBS plugin or declares).

I don't know the flags used by the navigation manager, but the MBS has
this property for the NSSavePanel class:

allowsOtherFileTypes

A Boolean value that indicates whether the receiver allows the user to
save files with an extension that’s not in the list of allowed types.

and I have seen that description on Apple's developer website also.
_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>

Search the archives:
<http://support.realsoftware.com/listarchives/lists.html>

Re: Save Dialog Box
Date: 26.01.09 19:29 (Mon, 26 Jan 2009 19:29:42 +0100)
From: Sven E Olsson

On 2009-01-26, at 18:57 , Joe Strout wrote:
>

Hi,

I have fixed it using the Cocoa Save Dialog. If set the document to
nil and then the suggested file name to just Untitled then it works as
it should ( The (old) Mac style ) ... and it is the correct way to do
so .. But some of my users have some problem to understand why things
should get hiccups when just trying to change the file extension.

But now all is happy agin...

Thanks for your response,
Sven E

> That's normal Mac behavior. If TextWrangler somehow manages to
> avoid it, it must be doing some really crazy stuff (or, it's just
> not supplying an extension on the suggested file name).
>
> Best,
> - Joe
>
> --
> Joe Strout
> Inspiring Applications, Inc.
> http://www.InspiringApps.com
>

_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>

Search the archives:
<http://support.realsoftware.com/listarchives/lists.html>

Re: Save Dialog Box
Date: 26.01.09 20:00 (Mon, 26 Jan 2009 12:00:57 -0700)
From: Joe Strout
Sven E Olsson wrote:

> I have fixed it using the Cocoa Save Dialog. If set the document to nil
> and then the suggested file name to just Untitled then it works as it
> should ( The (old) Mac style ) ... and it is the correct way to do so ..

If you're willing to set the suggested file name to just "Untitled" then
you don't need to use the Cocoa Save Dialog; the built-in one will do it
just fine. My test code (in a button on a window):

Dim d As New SaveAsDialog
d.SuggestedFileName = "Untitled"
Dim f As FolderItem = d.ShowModalWithin( self )
if f <> nil then Title = f.Name

Best,
- Joe

Re: Save Dialog Box
Date: 26.01.09 20:34 (Mon, 26 Jan 2009 20:34:56 +0100)
From: Sven E Olsson

Yes .. but then they need to type the name again, now they could just
change html to php ... ( and then it could be miss spelling and debug
time )

Regards Sven E

On 2009-01-26, at 20:00 , Joe Strout wrote:

> Sven E Olsson wrote:
>
>> I have fixed it using the Cocoa Save Dialog. If set the document to
>> nil and then the suggested file name to just Untitled then it works
>> as it should ( The (old) Mac style ) ... and it is the correct way
>> to do so ..
>
> If you're willing to set the suggested file name to just "Untitled"
> then you don't need to use the Cocoa Save Dialog; the built-in one
> will do it just fine. My test code (in a button on a window):
>
> Dim d As New SaveAsDialog
> d.SuggestedFileName = "Untitled"
> Dim f As FolderItem = d.ShowModalWithin( self )
> if f <> nil then Title = f.Name
>
> Best,
> - Joe
>
> --
> Joe Strout
> Inspiring Applications, Inc.
> http://www.InspiringApps.com
>

_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>

Search the archives:
<http://support.realsoftware.com/listarchives/lists.html>