Click here to Skip to main content
15,887,485 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
How to get the path of a particular folder in client machine from asp.net?

Does anybody have the answer?

i want the path of temp folder in client machine to save file and want to access it (and

save file without giving any information to the client) is it possible???????????

if yes give me solution plz........
Posted
Updated 18-Apr-11 20:27pm
v7
Comments
BobJanova 19-Apr-11 5:30am    
You should not do this. Saving files onto someone's computer without their consent is quite rude and only really useful for trojans/backdoors. If you want to save state information, use a cookie.

Might be possible via ActiveX, if the client's browser settings allow for it, BUT unless you're developing a closed shop solution for an intranet this not advisable. Why should anybody allow a web application to find any particular folder on their computers filesystem. That sounds very intrusive to me and would in my eyes not constitute acceptable behaviour for a web application.
If the server hides certain files from me and disallows inspection of it's folders, why should I allow the server to do this on my system?

Maybe if you elaborate your need for this scenario I could better comprehend and maybe find this path a viable one.

Best Regards,

-MRB
 
Share this answer
 
v4
Comments
#realJSOP 18-Apr-11 8:29am    
But anybody that doesn't have a sloping forehead or bresathes through their mouth would ever knowingly allow an ActiveX object on their machine. Oh wait... this is the internet...
Manfred Rudolf Bihy 18-Apr-11 8:40am    
Agreed!
That is more or less the tenor of what I said. :)
And besides all that it would only work for browsers that are enabled to host ActiveX elements.
Sergey Alexandrovich Kryukov 18-Apr-11 22:39pm    
Good point! My 5.
--SA
You can't just "get a path" from the client box in ASP.Net. It's simply not possible. It's called "security". Google is your friend.
 
Share this answer
 
Comments
Manfred Rudolf Bihy 18-Apr-11 8:43am    
Saying you can't is just as wrong as trying to go for such a solution. As I pointed out in my answer it could be done on browsers that are able to host ActiveX controls. I wouldn't allow for it on my computer, but OP has yet to answer my request for laying out his application scenario.
hope it will work Find files with JavaScript[^]
 
Share this answer
 
try dis ^
 
Share this answer
 
Comments
sabithaOrell 19-Apr-11 1:08am    
ok there is solution but i want to save file without giving any information to the client is it possible
and thank u for your reply
sabithaOrell 19-Apr-11 2:23am    
if you know the solution plz reply me soon

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900