On Wed, Nov 7, 2018 at 5:57 AM Dave Crozier <dcroz...@flexipol.co.uk> wrote:

> Unknown to me after all these years, the set default to command has an
> effect on the whole of the VFP thread not just the DataSession you are in.


To quote my co-author, "Computer language purists object to SET commands
for a pretty straightforward reason: the formation of the infinite-state
machine. Although that sounds cool,..." (
https://www.tedroche.com/hackfox7/s4g126.html)

SETs often have global effects which make their local use frustrating.

Three things:

1. If you were rewriting the app, you'd store a "Data Directory" in your
global settings table and precede all your file open commands with that.
That makes it INCREDIBLY easy to have a test mode that just switches that
setting. But you're not re-writing your app, so...

2. Adding another GLOBAL to solve this issue is putting out fire with fire,
but if you had your data directory in your SET PATH, would that solve
the problem?

3. I think you can replace the GetFile() command locally with one from the
Common Dialog set, which gives you finer control. I believe Doug Hennig
wrote a white paper on this one. (
http://doughennig.com/Papers/Pub/ModernUI.pdf)


--- StripMime Report -- processed MIME parts ---
multipart/alternative
  text/plain (text body -- kept)
  text/html
---

_______________________________________________
Post Messages to: ProFox@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/profox
OT-free version of this list: http://mail.leafe.com/mailman/listinfo/profoxtech
Searchable Archive: http://leafe.com/archives/search/profox
This message: 
http://leafe.com/archives/byMID/profox/CACW6n4ty+M1k+pAT90g6QToL+zWAkyrnPG43d=o-03y97q2...@mail.gmail.com
** All postings, unless explicitly stated otherwise, are the opinions of the 
author, and do not constitute legal or medical advice. This statement is added 
to the messages for those lawyers who are too stupid to see the obvious.

Reply via email to