May be you need setup the full path of your file ,as below
File f = new File(filePath);
f.mkdirs();
uma.k [EMAIL PROTECTED] wrote:
Hi Jay,
I tried this way too, but I am actually getting FileNotFoundException. This
is the modified code
String filePath = theForm.getFilePath();
Hi Venkat,
I give you these two links that Niall Pemberton gave me one month ago. I
think that you can find useful information to solve your problem.
aris
http://issues.apache.org/bugzilla/show_bug.cgi?id=21760
http://article.gmane.org/gmane.comp.jakarta.struts.user/96384
From: Venkat
Hello everybody,
I was wondering what is the best way to cope with transaction errors in a
Struts application. I use JDBC to connect to the database. When I try to do
an insert-transaction it looks like the code below the message (sample
form the Sun Tutorial).
My question is: what should I do
While I agree completely with your point about maintainability and
testability (I can't think of a single situation where I would ever
consider dynamic configuration modification), I'm interested in how this
might be allowed anyway...
Wouldn't it be possible to create a thread-safe
I am having a problem using indexed properties.
In my ActionForm I have the following:
private List files = new ArrayList();
public FileForm[] getFiles() {
return (FileForm[])files.toArray(new FileForm[files.size()]);
}
public FileForm getFiles(int index){
return
On Sun, 19 Dec 2004 09:53:55 -0500, Frank W. Zammetti
[EMAIL PROTECTED] wrote:
While I agree completely with your point about maintainability and
testability (I can't think of a single situation where I would ever
consider dynamic configuration modification), I'm interested in how this
might
Craig McClanahan wrote:
This is *exactly* where the problem lies. If one looks inside the
implementation of HashMap, one sees that there are times when the
internal data structures are being modified, and are in a potentially
inconsistent state that would corrupt a read operation happening on a
Hi
What is the prefer way to handle error messages via redirect?
Regards,
Ben
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
Just for a laugh, I'll post this... I had just typed up the following
response, when it dawned on me exactly why the problem is on the read
side. I think I was subconsciously thinking that locking the HashMap
during the write would prevent any read from occurring, this is
obviously not the
Cool ... this looks like a much better solution to the problem that
FastHashMap tried to solve. And I trust the implementors of this
library a *heck* of a lot more than I trust myself (I wrote
FastHashMap originally) to get all the nitpicky details right.
Craig
On Mon, 20 Dec 2004 10:17:11
Ben,
Your statement doesn't really give a lot of detail on what you're
trying to accomplish, but I'm going to take a stab:
Struts is going to save validation errors into the request. If you're
doing a redirect back to the input form when validation fails you're
going to wind up with a new
Along those lines, you might want to check out the backport of JSR 166
(java.util.concurrent):
http://www.mathcs.emory.edu/dcl/util/backport-util-concurrent/
And perhaps specifically ConcurrentHashMap:
http://tinyurl.com/6c98r
Craig McClanahan wrote:
Cool ... this looks like a much better
Since we are on this topic, any ideas on how to build images from a
webpage which is downloaded automatically into a database or a file
system. Eg would be google desktop style, where a thumbnail appears of a
html page beside a search item.
Regards,
Amin
Just carry the path of the file, not
Hi David,
I copied jstl.jar to WEB-INF/lib and errors still occur when I compiled
the project.
I am using JDeveloper 10g with jdk 1.4.2 to develop my project.
Could you tell me how to use standard jstl in my case.
Thanks Regards,
Dang Minh Phuong
Karr, David [EMAIL PROTECTED]
12/18/2004
Hi,
I am using struts validator plugin. I have form field which requires
following validation:
Full Name can contain only letters, dashes (-), apsotrophes(') and
single spaces
Here is the regex I am using for this validation : ^[a-zA-Z'-\s]*$
The only problem with this regex is that it allows user
Hmm, that's one I've never tried... Just to be sure I understand, you
basically want to be able to render a page and then produce an image of
it, and store that either to a database or file system? If so, that's
certainly an interesting request...
I can't vouch for this program, I just looked
^([a-zA-Z]+['-\s])*$
That's top of my head ... and my head is tired :-( but maybe it's
helpful. You need to separate the repeating things from the
non-repeating things, and allow the two of them to be chained multiple
times. Having such complete validation of a name seems error-prone at
best
NO, this might not be best solution as the folders are already existing and
If I have to move from one OS to another OS then this would be a problem.
So, I wanted to upload the file to relative path rather than absolute path.
Any one please?
-Original Message-
From: yue pengfei
Thanks for the tip on StrutsTestCase. This is exactly what I have been
looking for. Now I can TDD with my Actions. How cool is that? If you
want to do unit testing of your Actions and Forms without the browser,
then get StrutsTestCase. And make sure you are using at least Struts
1.2.4.
JSP:
%@ taglib uri = /WEB-INF/struts-html.tld prefix = html%
%@ taglib uri = /WEB-INF/struts-bean.tld prefix = bean%
%@ taglib uri = /WEB-INF/struts-logic.tld prefix = logic%
html:html xhtml = true
html:form action = uploadFile enctype = multipart/form-data
html:file property = file2Upload /
The sample of Tiles contains text only.
Can I put images instead of texts where points to a URL?
So that it is more nice looking to click an image.
Please show a way.
Thanks
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For
Hi Sunny,
Thanks for the reply. I will try it out and get back.
Thanks
Uma
-Original Message-
From: Sunny [mailto:[EMAIL PROTECTED]
Sent: Monday, December 20, 2004 12:21 PM
To: Struts Users Mailing List
Subject: Re: file upload problem
JSP:
%@ taglib uri = /WEB-INF/struts-html.tld
22 matches
Mail list logo