Hi Norman.

I have now switched to using the code f = GetSaveFolderItem (FileTypes.MacBaseDatabase,"Untitled Database.mbs") which works fine, documents now open in the right App.

My only problem now is icons for the files generated. I create the file, Untitled Database.mbs on my Desktop. However, the icon for this file is blank, nothing. If I restart Finder, the icon then appears.

Is this a bug or am I doing something wrong.

Giles.

On 7 Jun 2006, at 15:55, Norman Palardy wrote:


On Jun 06, 2006, at 11:54 PM, Giles Williams wrote:

Hi.

Thanks Norman, that now works if I drag a file onto the icon.

I still have one problem.

I am using a RealSQLDatabase file to save the documents created.

But, when I use the code below to save it, it still saves as Document Type: Realbasic 2005 File!?

  Dim dlg as New SaveAsDialog
  Dim f as FolderItem
  dlg.InitialDirectory= Volume(0).Child("Documents")
  dlg.SuggestedFileName="Untitled Database.gbs"
  dlg.Filter = FileTypes.MacBaseDatabase

  f=dlg.ShowModal()
  If f <> Nil then
    //file is to be saved
    Dim db as REALSQLdatabase
    db= New REALSQLdatabase
    db.databaseFile=f
    If db.CreateDatabaseFile then

Add
        f.MacCreator = ....
        f.MacType = ....

and set those to whatever type you have defined for your documents
_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>

Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>

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

Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>

Reply via email to