PDA

View Full Version : CSIDL paths changing



NewsArchive
08-29-2011, 03:03 AM
Friedrich - as per a post in the C8 NG I have an issue.

For some unknown reason, every so often my CSIDL folder path changes.
Nothing goes wrong on my machine but the hardcoded paths in SB change.

For example, until a couple of days ago my SB paths used to collect my data
into the script were hardcoded into SB as C:\Users\Public\Public
Documents\....... This is direct from choosing the files from the
Visualizer.

Yesterday my scripts failed because the path had changed and dropped the
PUBLIC from Documents, so this now became C:\Users\Public\Documents \.....

I have no idea why this happens although I suspect it might be a Windows
update that does it. My Clarion apps are fine as I use Winevent to get the
CSIDL folder but it seems that SB is getting broken from time to time.

I know it is not the fault of SB but is there any way this can be avoided.
After all when using the Visualizer I am using the CSIDL folders.

If you check out the attched screenshots sb1 shows the CSIDL folder usage
and how this translates to the file properties. Now check out sb2 - this
shows the CSIDL path being hard coded into the script. That is fine until
something changes the path. When I recompile the script of course it all
fails as the path does not exist. Somehow there needs to be a mechanism that
refreshes the CSIDL path?????

Many thanks

John Fligg

NewsArchive
08-29-2011, 03:51 AM
Hi John,

You are right. This has nothing to do with SB and no, SB is not getting
broken from time to time!

But did you post the correct screenshots? I do not see any CSIDL compiler
variable in your dialogs. The first screenshot displays the "Location"
path. This is the path on the TARGET machine. The second screenshot shows
the hard-coded "Source Folder" (that's the folder location on your machine).
No CSIDL is involved in your case so SB can't "refresh" anything.

And it always depends on which operating system (mode) you're running.

For XP it's something like:
C:\Documents and Settings\All Users\Documents\Ambrit Software\Vet
Manager\Data

For Vista it should be:
C:\Users\Public\Documents\Ambrit Software\Vet Manager\Data

Please note the "...Public\Documents..." (and not ..."Public\Public
Documents...")

For Windows 7 it is:
C:\Users\Public\Public Documents\Ambrit Software\Vet Manager\Data

Friedrich

NewsArchive
08-30-2011, 01:23 AM
Hi John,

> For some unknown reason, every so often my CSIDL folder path changes.
> Nothing goes wrong on my machine but the hardcoded paths in SB change.

Perhaps this is just the way Vista etc displays the paths.
Have a look at the screenshots (attached) from Vista Home Premium (this is
using (My) Computer to navigate folders)

From Public.JPG
-----------------
Navigating to \Users\Public shows the public folders as
Users\Public\Public Documents
Users\Public\Public Downloads

etc - NB the 'extra' 'Public'

From PublicDocuments.JPG
----------------------------
If you go into Public\Public Documents then the address bar still shows the
path as c:\Users\Public\Public Documents

From ClickInAddress.JPG
---------------------------
But if you click in the address bar the path changes to what it actually is
on disk ie c:\Users\Public\Documents

c:\Users\Public\Documents is also what you'll see if you use a command
prompt to navigate to the location.

HTH

Graham