Simplicty and flexibility!


GetFileName Issue


Started by Jeyarajah Arulrajah
Search
You will need to Sign In to be able to add or comment on the forum!

GetFileName Issue

Download: GetFileIssue.zip

I am using something like this;
SetValue("Filename",GetFileName("","","C:\temp\")) .

As you will see in the above, I want the file browse to open "C:\temp\" all the time.
But, if you open browse into some other folder like for an example 'C:\Program Files (x86)\DataEase\DataEase 8.5' to pickup the file, after that each time when you use this function it goes into that last viewed folder (C:\Program Files (x86)\DataEase\DataEase 8.5).

I am attaching a sample database in DE8.5 with blank userID and blank password.


Written by Jeyarajah Arulrajah 25/01/16 at 03:06:11 Dataease [{8}]FIVE

Re:GetFileName Issue

I hate using this sentence but it is "As designed..." ;-)

Not by the CDF developer (yes it is a CDF and we don't have the source code so we wouldn't be able to change it we wanted to) but by Microsoft which is to maintain the last opened catalogue throughout the session.

I must say that I personally prefere this as it follow my train of thought, and we have many cases in DFW where always opening in the same catalogue is a nightmare. One instance that comes to mind is Install document where you used to have to start on top of your computer and drill down for every document....(luckily changed now in 85 to always open the same catalogue so you can simply pick them at your leisure).

So every fix is an un-fix for someone else.

When starting on DE8 we prioritised everything "missing" in the product first so if it was supported by a workaround (that actually worked/was easy) or there was a CDF for it we didn't prioritise it.

But our general policy is that no mainstream function/functionality in DataEase should be a CDF so we have scheduled a "GetFileName" as part of DEOS.

We have not yet defined how it should be used, and as the keep active catalogue is the default behaviour that will obviously be the default way here too, but there might be a possibility that we can include a switch that allow you to override this.


Written by DataEase 26/01/16 at 12:17:52 Dataease [{8}]FIVE

Re:Re:GetFileName Issue

Good to know, I am not doing something wrong here:-)

Anyways, as always we find our own workaround in DataEase.


Written by Jeyarajah Arulrajah 26/01/16 at 14:37:58 Dataease [{8}]FIVE

Re:Re:Re:GetFileName Issue

So what is the workaround Arul. 

I was wringing my head to try to find one, but other than closing and restarting Dataease I didn't think of one as the problem is that it happens on initiation of the session i.e. when the CDF is loaded first time.


Written by DataEase 26/01/16 at 14:58:02 Dataease [{8}]FIVE

Re:Re:Re:Re:GetFileName Issue

Workaround is to use a 3rd party EXE file to select the file and put that file name and path into clipboard.

Then DataEase will immediately pickup.

Good thing about this 3rd party EXE, it will open the folder based on what we tell it to do....

This EXE file was created using;
https://www.autoitscript.com/site/autoit/


Written by Jeyarajah Arulrajah 26/01/16 at 15:01:19 Dataease [{8}]FIVE
DG3_ForumList