From: Webbiz on
I've run into a little problem with my current project.

I created a file and gave it my own filetype of .fdr.

Problem: When the user goes to download this file, it shows up in the
download directory dialog as "myfile.unk". In other words, it has the
..unk filetype because my Windows system does not know what a .fdr file
is.

Is there a way via code to add the .fdr filetype to the system?


Problem 2:

I want the user to download this .fdr file to his application
directory.

The directory defaults to c:\Program Files\MyApp

For Windows 7 (and likely Vista), it will not allow the downloading of
the file to write to this default directory.

Is there a way to make it do so, or do I have to create a separate
directory elsewhere as my only alternative.


Thanks.

Webbiz
From: Karl E. Peterson on
Webbiz wrote:
> I've run into a little problem with my current project.
>
> I created a file and gave it my own filetype of .fdr.
>
> Problem: When the user goes to download this file, it shows up in the
> download directory dialog as "myfile.unk". In other words, it has the
> .unk filetype because my Windows system does not know what a .fdr file
> is.
>
> Is there a way via code to add the .fdr filetype to the system?

You can create a file association, certainly. That'd be what to
google.

But I wonder if part of the problem here isn't what mime-type the
server is telling your system that file is? This might require action
on both ends, but I'd probably be looking at the server first.

> Problem 2:
>
> I want the user to download this .fdr file to his application
> directory.
>
> The directory defaults to c:\Program Files\MyApp
>
> For Windows 7 (and likely Vista), it will not allow the downloading of
> the file to write to this default directory.
>
> Is there a way to make it do so,

No. Not short of totally altering the permissions on the machine.

> or do I have to create a separate
> directory elsewhere as my only alternative.

Yes.

Lemme Tell Ya Where To Stick It -- Visual Studio Magazine
http://visualstudiomagazine.com/articles/2009/01/19/lemme-tell-ya-where-to-stick-it.aspx

--
..NET: It's About Trust!
http://vfred.mvps.org


From: Webbiz on
I'm considering creating a folder under the user's DOCUMENTS
directory.

How do you get the PATH to the users DOCUMENTS directory regardless of
what version of Windows they are running on?

XP appears to be "Documents and Settings" and Windows 7 is "Library"?

A tad confused.

Thanks.

Webbiz

From: Karl E. Peterson on
Webbiz wrote:
> I'm considering creating a folder under the user's DOCUMENTS
> directory.
>
> How do you get the PATH to the users DOCUMENTS directory regardless of
> what version of Windows they are running on?
>
> XP appears to be "Documents and Settings" and Windows 7 is "Library"?
>
> A tad confused.

See my response to your first post.

--
..NET: It's About Trust!
http://vfred.mvps.org


From: C. Kevin Provance on

"Webbiz" <nospam(a)noway.com> wrote in message news:at2gp5d9akg1upd9naab1f6ptq32hlt7mc(a)4ax.com...
: I'm considering creating a folder under the user's DOCUMENTS
: directory.
:
: How do you get the PATH to the users DOCUMENTS directory regardless of
: what version of Windows they are running on?
:
: XP appears to be "Documents and Settings" and Windows 7 is "Library"?
:
: A tad confused.

I do believe the answer to that question is in Karl's article.