Real Software Forums

The forum for Real Studio and other Real Software products.
[ REAL Software Website | Board Index ]
It is currently Sat Jun 23, 2018 8:52 pm
xojo

All times are UTC - 5 hours




Post new topic Reply to topic  [ 3 posts ] 
Author Message
 Post subject: Problems converting 2007 REALbasic to 2012 RealStudio
PostPosted: Sat Jan 05, 2013 3:48 pm 
Offline

Joined: Tue May 08, 2007 9:48 am
Posts: 25
Good afternoon. I'm in the process of recompiling a 2007 REALbasic program using Real Studio 2012 Release 2.

Yesterday I asked a question about 'ApplicationSupportFolder' and received two answers which I'm not smart enough to take advantage of. (I should note that I'm 79 and haven't programmed in five years.) The compiler's error message was "This item does not exist".

So today I'm back with the question - but I'm showing the code around it:

OwnManAcctDB = New REALSQLDatabase
Dim f, g, h as FolderItem
f = ApplicationSupportFolder
if f = nil
...
endif

fpath = f.AbsolutePath + "Holdin's Holdings TB"
g = GetFolderItem(fpath)
if not g.exists then
h = new FolderItem(fpath)
h.CreateAsFolder
end if

ALSO. It tells me that over 100 of my controls are based on a deprecated class. HELP?

Tom Bisbee - in the hills of Vermont.


Top
 Profile  
Reply with quote  
 Post subject: Re: Problems converting 2007 REALbasic to 2012 RealStudio
PostPosted: Sat Jan 05, 2013 4:12 pm 
Offline
Real Software Engineer

Joined: Sat Dec 24, 2005 8:18 pm
Posts: 7858
Location: Canada, Alberta, Near Red Deer
Tom Bisbee wrote:
OwnManAcctDB = New REALSQLDatabase
Dim f, g, h as FolderItem
f = ApplicationSupportFolder
if f = nil
...
endif




OwnManAcctDB = New REALSQLDatabase
Dim f, g, h as FolderItem
f = SpecialFolder.ApplicationData
if f = nil
...
endif

_________________
Norman Palardy (Real Software)


Top
 Profile  
Reply with quote  
 Post subject: Re: Problems converting 2007 REALbasic to 2012 RealStudio
PostPosted: Sat Jan 05, 2013 5:22 pm 
Offline

Joined: Mon May 30, 2011 12:56 am
Posts: 702
and...

fpath = f.AbsolutePath + "Holdin's Holdings TB"
g = GetFolderItem(fpath)
if not g.exists then
h = new FolderItem(fpath)
h.CreateAsFolder
end if


becomes

dim myfolder as folderitem
myfolder = f.child("Holdin's Holdings TB")

if not myfolder.exists then
myfolder.CreateAsFolder
end if


Select all the controls, allow RB to update them. (usually a non change like static text > label)
Save the project with a new name, and start from there.


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 3 posts ] 

All times are UTC - 5 hours


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

Search for:
Jump to:  
cron
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group