[V4RB] Convert database 1 to 3?

Beatrix Willius bwillius at gmx.de
Sat Aug 23 03:25:05 CDT 2008


The following works:

   if valentina.GetDatabaseFormatVersion(theFolderitem) < &h200 then

     wasOldDBFormat = true
     'rename old file, get a unique name
     dim OldFolderitem as FolderItem = theFolderitem
     dim theName as String = OldFolderitem.Name
     dim currentFileInt as Integer = 1
     if OldFolderitem.Parent.Child(theName + " Old").Exists then
       While OldFolderitem.Parent.Child(theName + " Old " + str 
(currentFileInt)).Exists
         currentFileInt = currentFileInt + 1
       Wend
       OldFolderitem.Name = theName + " Old " + str(currentFileInt)
     Else
       OldFolderitem.Name = theName + " Old"
     end if

     'create new file
     theFolderitem = nil
     theFolderitem = OldFolderitem.Parent.Child(theName)
     if theFolderitem.LongPathMBS <> OldFolderitem.LongPathMBS then
       Valentina.Convert_1_2(OldFolderitem, theFolderitem, true, "", "")
       wasConverted = True
     end if
   else
     wasConverted = True
   end if

On 23.08.2008, at 08:15, REALBasic wrote:

> It has been a while. I just wish the examples had all been updated. I
> was hoping someone had an update routine that worked.
>

Mit freundlichen Grüßen/Regards

Trixi Willius

http://www.mothsoftware.com
Mail Archiver X: archive, clean and search email
http://www.beatrixwillius.de
Fractals, 3d landscapes etc.



More information about the Valentina mailing list