C#
filePath = FileUpload1.PostedFile.FileName;
But I'm getting only filename instead of full pathfilePath = FileUpload1.PostedFile.FileName;
But I'm getting only filename instead of full pathKnow the answer? Post it. Somebody with the same question will find it here.
Answer a question in the forums and earn +20 SHARP for every answer.
See unanswered questions
DevSocialUpcoming · 3rd editionAI Agents ConferenceDec 1–3, 2026Live onlineFree to attend5days leftRegister
TulasiRank #2,544 · 549 reputationPosted Oct 3, 2013, 4:40 AM EDT
FileUpload1.PostedFile.FileName it gives u complete file path in some browser. but this feature has been disabled due to security reasons.
please have a look on this below link .
http://www.codeproject.com/Questions/169238/FileUpload-PostedFile-FileName-not-giving-full-pat
Jignesh TrivediRank #16 · 50.3K reputationPosted Oct 3, 2013, 5:23 AM EDT
hi,
When we upload file, the browser will send only the souce file name not full file path, this value can be check by using FileUploadControl1.PostedFile.FileName property.
so i thing it is not posible to get full path....
hope this will help you.