Photo Gallery Example solution question

Questions and answers on designing your Servoy solutions, database modelling and other 'how do I do this' that don't fit in any of the other categories

Photo Gallery Example solution question

Postby DFehrenbach » Thu Dec 02, 2004 1:16 am

I found the example solution quite interesting. One nagging question is:
How can one start the application.showFileOpenDialog with the path that was used last? Starting at the root position each time is very inconvenient if you have a large number of images to add to the album.
Dennis Fehrenbach
DFehrenbach
 
Posts: 252
Joined: Sat Sep 13, 2003 6:48 pm
Location: Cleveland, OH

Re: Photo Gallery Example solution question

Postby Riccardino » Thu Dec 02, 2004 10:49 am

DFehrenbach wrote:I found the example solution quite interesting. One nagging question is:
How can one start the application.showFileOpenDialog with the path that was used last? Starting at the root position each time is very inconvenient if you have a large number of images to add to the album.


Even if I'm afraid it's a java thing, I strongly agree with this point :-)
ciao, ric
User avatar
Riccardino
 
Posts: 911
Joined: Thu Apr 24, 2003 11:42 am
Location: Ferrara, Italy

Postby Harjo » Thu Dec 02, 2004 1:09 pm

Use the file-plugin with a global instead!

Try this: create a global: lastfilepath an make the method:

Code: Select all
filename = plugins.file.showFileOpenDialog(0,globals.lastfilepath);
if (filename)//for cancel
{
//do something here
globals.lastfilepath = normalizedFileName

}
Harjo Kompagnie
Direct ICT / Servoy Hosting / ServoyCamp
Servoy Certified Developer
Servoy Valued Professional
SAN Developer
User avatar
Harjo
 
Posts: 4309
Joined: Fri Apr 25, 2003 11:42 pm
Location: DEN HAM OV, The Netherlands

Postby maarten » Thu Dec 02, 2004 1:38 pm

you can also store lastUsedFilePath in your database, linked to user_id.
Maarten Berkenbosch
User avatar
maarten
 
Posts: 797
Joined: Wed Apr 23, 2003 10:52 pm
Location: Amersfoort, Netherlands


Return to Programming with Servoy

Who is online

Users browsing this forum: No registered users and 10 guests

cron