Page 1 of 4

Default Directory locations

Posted: Sat May 21, 2016 7:36 am
by RJHollins
OK ... this is dumb ... but suppose to be simple.

I'm using the FILE Dialog prim.

I'm setting the START FOLDER with a STRING entry. This location is the STRING OUTPUT from the File Dialog.

Shouldn't this set a DEFAULT location ??

I'm needing several of these to handle different files [stored to different locations], but I'd like the initial choosen location to be set as DEFAULT, so as to return to that spot the next time. Some are LOAD only, some are SAVE operations.

I've tried several strategies ... even Sample/Hold triggered. The locations don't stick and change when I do other location assignments. None of these routines are connected to each other ... they are separate in the project.

Note: this is my first EXE program using FS [if that matters].

What the heck could be so tough about this ??? I am doing something wrong :twisted:

Help :|

Re: Default Directory locations

Posted: Sat May 21, 2016 10:12 am
by tulamide
Post an example, please.

Re: Default Directory locations

Posted: Sun May 22, 2016 8:29 am
by RJHollins
OK ... there must be something sooo simple that I've overlooked. I have tried many ways ... none of them work, at least not the way I need.

Sure ... if I only use a single module, to access a single location, the current schematic goes there. However, If I try to set up another module, doing the same thing, but locating to a different directory ... only the last location is gone to by BOTH separate modules. It's like they are sharing the same data, but they don't, and are not suppose to.

Here's a screen shot:
Screen-1.jpg
Screen-1.jpg (42.89 KiB) Viewed 25145 times


and the test schematic:
Default Directory-1.fsm
(4.73 KiB) Downloaded 973 times


I'm only showing the single module that needs to have a set default [the last location loaded]. I NEED to have several of these [separate] that I can use to default locations.

Simply ... if working correctly, it should not matter how many default directory modules used in a project. Each module is separate and should work unto itself.

Anyway ... I'm really disappointed that I've not been able to solve this :|

Appreciate anyone that can correct my error [s].

Thanks GANG.

Re: Default Directory locations

Posted: Sun May 22, 2016 11:57 am
by tulamide
Remove the sample and hold section.
Screenshot_1.png
Screenshot_1.png (22.3 KiB) Viewed 25135 times

Re: Default Directory locations

Posted: Sun May 22, 2016 12:00 pm
by Walter Sommerfeld
Hi

remove the direct Path splitter outputs back loop to the Path and filename...!

Then sample&hold the 1st selected and feed them to the other file dialogs as default?!

oops - tulamide was faster

Re: Default Directory locations

Posted: Sun May 22, 2016 5:26 pm
by RJHollins
tulamide wrote:Remove the sample and hold section.
Screenshot_1.png

I ADDED the Sample/Hold section because it didn't work ... and still doesn't.

To be clear ... using the module by itself [only one directory] ... it does remember the location.

NOW ... duplicate the module. Now try to set up 2 different default locations.

The example being:

LOAD from a default location

SAVE to a different default location.

The 'Default' would be the Last location the User set with FileDialog selection.

Re: Default Directory locations

Posted: Sun May 22, 2016 8:56 pm
by tulamide
Hey RJ,

if your problem is with saving, why are you giving an example fsm that is all about loading? Provide an example that exactly shows the problem you have, for us to be able to look for potential issues.

Re: Default Directory locations

Posted: Mon May 23, 2016 12:48 am
by RJHollins
Both LOAD and SAVE default locations are issue. I'm using [basically] the same PRIMS [in 2 separate modules].

I'll rip that section and post ...

Re: Default Directory locations

Posted: Mon May 23, 2016 12:54 am
by RJHollins
OK ... here's the portion of the schematic that is suppose to assign a default location [based on the LAST used, separate/different for Load and Save]. In otherwords ... Load default will be different than Save default.

Default Directory-2.fsm
(6.75 KiB) Downloaded 941 times


Note ... I have other variations of this intent ... and none work :|

Thanks Guys.

Re: Default Directory locations

Posted: Mon May 23, 2016 1:32 am
by tulamide
RJ I'm sorry, but your schematic works perfectly fine here. Exactly as you expect them to work according to your descriptions. Two default paths, one for loading, one for saving, it's always the last used one and it's always the correct one wether loading or saving.