Click here to Skip to main content
15,892,072 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
How to construct root path from registry editor when execute program in web server,while executing in local path im getting as ""C:\Users\Desktop\SPHelper.exe" "%1"" but in web server im getting in this format ""webserver\Dot net upload\SPHelper.exe" "%1".How to construct root path in web server in complete format? for example("\\webserver\Dot net upload\SPHelper.exe""%1")
Posted
Comments
Suvendu Shekhar Giri 6-Apr-15 2:05am    
Is this really a question? You have tagged both VB.Net and C#, why?
Sergey Alexandrovich Kryukov 6-Apr-15 2:41am    
Strictly speaking, why not?

Nevertheless, you are right, the question is not clear. But more importantly, it does not seem to make any sense, by the reason I explained in Solution 1, please see.

—SA
SathishRam 6-Apr-15 7:55am    
then teach me,how to ask?
Here solution for that "System.Reflection.Assembly.GetExecutingAssembly().Location"
(this is VB.Net Or C#)
SathishRam 6-Apr-15 7:59am    
then teach me,how to ask?
Here solution for that "System.Reflection.Assembly.GetExecutingAssembly().Location"
(this is VB.Net Or C#)

1 solution

It all makes no sense. Web servers work with relative paths or the paths relative the the directory set up as a root for a Web site, other directories are not accessible to Web application/sites.

Typically (at least for well-known servers, such as IIS or Apache), your server-side code is executed in the sandboxed environment which don't allow access to any file system objects beyond the root directories. Anyway, you cannot talk about your desktop directory access, or anything like that. It all simply makes no sense.

—SA
 
Share this answer
 

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