This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes Other Open Source Projects and the fly likes How to Get Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Products » Other Open Source Projects
Bookmark "How to Get "Browsed File Path"?" Watch "How to Get "Browsed File Path"?" New topic
Author

How to Get "Browsed File Path"?

meruva surendra
Greenhorn

Joined: Jul 28, 2013
Posts: 24
Hi,
I want exact file path of uploaded file.Help Me...

My code is like this

public ActionForward execute(ActionMapping mapping, ActionForm form,
HttpServletRequest request, HttpServletResponse response)
throws Exception {
Upload_Csv_Form ucf=(Upload_Csv_Form)form;
File file=ucf.getFile();


Advance Thanks,
Rakesh Keerthi
Ranch Hand

Joined: Jul 16, 2012
Posts: 136
Hi,

you can try



here 'file' is the object/instance you create for File(sorry for my bad explanation, you would understand from below example).



and call this file object with getAbsolutePath() method as shown in my Answer's 3rd line.
 
Don't get me started about those stupid light bulbs.
 
subject: How to Get "Browsed File Path"?
 
Similar Threads
Form bean not taking the value when property is disabled in jsp
MAC OS X path
inputting the excel file to java servlet pgm
ContextPath Query