From: Kevin Provance on

"Eduardo" <mm(a)mm.com> wrote in message
news:gien1b$4uu$1(a)news.motzarella.org...
| I cannot limit it to Win98 and above.
| BTW, I already fixed it in one of my programs. fortunately I thought about
| this problem before I did any release.

Okay...I'm just telling you what I know.


From: Eduardo on
"Kevin Provance" <kevin(a)removetpasoftremove.com> escribi� en el mensaje
news:%23oIOkwWYJHA.4676(a)TK2MSFTNGP03.phx.gbl...
>
> "Eduardo" <mm(a)mm.com> wrote in message
> news:gien1b$4uu$1(a)news.motzarella.org...
> | I cannot limit it to Win98 and above.
> | BTW, I already fixed it in one of my programs. fortunately I thought
> about
> | this problem before I did any release.
>
> Okay...I'm just telling you what I know.

Thanks.


From: MikeD on

"Eduardo" <mm(a)mm.com> wrote in message news:giefl7$hqs$1(a)news.motzarella.org...
> Hi,
>
> Reading about checking directories existence and creating directories, a
> question came to my mind.
>
> I recentry changed the place where some of my programs save the data to make
> them Vista compliant, so I retrieve the APPDATA path and create a new folder
> there (if it doesn't exists already) and save the files there.
>
> But doing so I am relying on that the directory APPDATA will already exist
> in the client machine.
> My question is, can I rely that it will exist in Win95 and NT4 systems?
>

IIRC, some form of an AppData folder exists in all versions of Windows since Win98. But the path can still vary from OS to OS. Are you retrieving this path using the API (for example, SHGetSpecialFolderPath)?

If your app still needs to support Win95 and WinNT4, you probably need to write extra code to ensure compatiblity or settle on a different folder, such as "My Documents" (still need to use SHGetSpecialFolderPath to get that as it will be different from OS to OS, and even determine if you want it for all users or only the logged in user).


--
Mike





From: Eduardo on
"MikeD" <nobody(a)nowhere.edu> escribi� en el mensaje
news:%23tI3rtXYJHA.684(a)TK2MSFTNGP04.phx.gbl...

> IIRC, some form of an AppData folder exists in all versions of Windows
> since Win98.
> But the path can still vary from OS to OS. Are you retrieving this path
> using the API
> (for example, SHGetSpecialFolderPath)?

Yes.


> If your app still needs to support Win95 and WinNT4,

Yes, i need to support all Win32 versions.


> you probably need to write extra code to ensure compatiblity or settle on
> a different folder,
> such as "My Documents" (still need to use SHGetSpecialFolderPath to get
> that as it will
> be different from OS to OS, and even determine if you want it for all
> users or only the logged
> in user).

What i already did in one of my programs is what the link that Karl pointed
explained, that is:
check first if it is NT, then the Shell version:

Public Function FolderToWrite () As String

If IsNT Then
If ShellVersion >= 5 Then
FolderToWrite = GetAppDataFolder
End If
End If

If FolderToWrite = "" Then
FolderToWrite = App.Path
End If

If Right (FolderToWrite, 1) <> "\" Then
FolderToWrite = FolderToWrite & "\"
End If

End Function

I wasn't writing to App.Path in that case, but for the example it is OK.

PS: I'm not copying here the functions IsNT, ShellVersion and
GetAppDataFolder.


From: C. Kevin Provance on
Did Win95 have a "MyDocuments" folder?? I'm probably wrong, but I can't
help but remember that started with Win98.

"MikeD" <nobody(a)nowhere.edu> wrote in message
news:%23tI3rtXYJHA.684(a)TK2MSFTNGP04.phx.gbl...

"Eduardo" <mm(a)mm.com> wrote in message
news:giefl7$hqs$1(a)news.motzarella.org...
> Hi,
>
> Reading about checking directories existence and creating directories, a
> question came to my mind.
>
> I recentry changed the place where some of my programs save the data to
> make
> them Vista compliant, so I retrieve the APPDATA path and create a new
> folder
> there (if it doesn't exists already) and save the files there.
>
> But doing so I am relying on that the directory APPDATA will already exist
> in the client machine.
> My question is, can I rely that it will exist in Win95 and NT4 systems?
>

IIRC, some form of an AppData folder exists in all versions of Windows since
Win98. But the path can still vary from OS to OS. Are you retrieving this
path using the API (for example, SHGetSpecialFolderPath)?

If your app still needs to support Win95 and WinNT4, you probably need to
write extra code to ensure compatiblity or settle on a different folder,
such as "My Documents" (still need to use SHGetSpecialFolderPath to get that
as it will be different from OS to OS, and even determine if you want it for
all users or only the logged in user).


--
Mike