[V4Rb ] GetDatabaseVersion question

Charles Yeomans yeomans at desuetude.com
Tue Jun 28 13:05:33 CDT 2005


On Jun 28, 2005, at 2:17 AM, Ruslan Zasukhin wrote:

> On 6/28/05 2:11 AM, "Charles Yeomans" <yeomans at desuetude.com> wrote:
>
> Hi Charles,
>
>> I had thought that I would use GetDatabaseVersion to check to see if a
>> db file was a version 1.x file, but calling it on such a file results
>> in an exception.  Is this the intended behavior?
>
> No.
>
> Please check our example Common/Convert_1_2
>
> It use this function to define version of db.
> Then do convert_1_2.
>
> You can try open your db by this example.
> Example works as simple general utility.
>
> Let me know if any problems
>
> What version of V4RB do you use ?

I was using 2.0.3.  I have now tried the example code with 2.0.4fc10.   
GetDatabaseVersion now returns a version instead of an exception.  But  
the app crashes when Convert1_2 is called, right about here --

Thread 0 Crashed:
0   Kernel_Carbon_Final.shlb       	0x0294d3ac  
AddToIndex__Q23fbl5VTextFUl + 0x108
1   Kernel_Carbon_Final.shlb       	0x0273f874  
AddRecordToIndex__Q23fbl5TableFUlQ23fbl24smart_ptr<Q23fbl6BitSet> +  
0x100
2   Kernel_Carbon_Final.shlb       	0x02958f04  
AddRecord__Q23fbl5TableFv + 0x12c
3   Kernel_Carbon_Final.shlb       	0x029e20f8  
Convert_Current_Record_1_2__3fblFP14VDK_BaseObjectQ23fbl27smart_ptr<Q23f 
bl9I_TableEx> + 0x2e4
4   Kernel_Carbon_Final.shlb       	0x029e1d3c  
LoadData__3fblFP12VDK_DataBaseQ23fbl31smart_ptr<Q23fbl12I_DatabaseEx> +  
0x144
5   Kernel_Carbon_Final.shlb       	0x029dfcc4  
ConvertDB_1_2__3fblFQ23fbl29smart_ptr<Q23fbl10I_Location>Q23fbl29smart_p 
tr<Q23fbl10I_Location>bUl + 0x244
6   Plugin                         	0x024aea64  
Valentina_Convert_1_2__FP20REALfolderItemStructP20REALfolderItemStructii 
  + 0x188
7   main                           	0x0041c278 0x405000 + 0x17278
8   main                           	0x00408750  
Window1.Window1.PushButton1_Action%%o<Window1> + 0x310


You should be able to use the same file I made available for my other  
question to reproduce the crash.

--------------
Charles Yeomans



More information about the Valentina mailing list