I managed to get the problem working, unfortunately that fix is by doing
something that is against best practices (if I understand them correctly).
To get this to work what I ended up doing was pulling the results from the
search and putting that in the reset of the resultsAction. I am pretty
cer
It's more likely that I don't understand. This is my first struts project
and I am learning as I go.
Here is all of the getters/setters that I have so far. It is quite possible
that I am missing some, but the previous page that I created that works used
only those listed, and it works fine. T
On 10/20/06, Adam K <[EMAIL PROTECTED]> wrote:
Getter and setter methods for ? (Sorry if it should be obvious but I want
to clarify as it isn't obvious to me)
for numProducts indexed property. And i dont understand why are you
populating blank values in the getter methods..I mean you should
Getter and setter methods for ? (Sorry if it should be obvious but I want
to clarify as it isn't obvious to me)
As far the error message here is what I recieve:
javax.servlet.ServletException: BeanUtils.populate
org.apache.struts.util.RequestUtils.populate(RequestUtils.java:495)
On 10/19/06, Adam K <[EMAIL PROTECTED]> wrote:
Here are the 2 get methods that I have.
thanks again for all the help.
public int getNumProducts() {
return numProducts;
}
public int getNumProducts(int index)
{
if(this.results== null)
{
this
One other thing I just realized that I should include is the fact that all
of my forms are request based, which doesn't allow me to include the form
information from one to the next, so to get around that (for more testing) I
have included the array in a Session variable so that I can pull it out
If this is a bad technique I would be more than happy to change it to a more
standard technique. Any suggestions on how to improve my code are always
welcome.
thanks for the suggestions thus far.
Adam
On 10/19/06, Chris Pratt <[EMAIL PROTECTED]> wrote:
I don't think I've ever seen that techni
I don't think I've ever seen that technique before, but you have to remember
that size() is 1 based and index (or get(index) ) is 0 based. So when
someone calls getNumProducts(5), your while loop fills in indexes 0, 1, 2,
3, and 4 (because then index and this.results.size() are both 5), then you
Here are the 2 get methods that I have.
thanks again for all the help.
public int getNumProducts() {
return numProducts;
}
public int getNumProducts(int index)
{
if(this.results== null)
{
this.results = new ArrayList();
}
while(index >
On 10/19/06, Adam K <[EMAIL PROTECTED]> wrote:
Hi all I have been working on this probelm for the past couple of days,
and
don't seem to be making any progress on it. I am fairly certain it is a
problem with my understanding of struts, and as such it makes it quite
difficult for me to solve the
Hi all I have been working on this probelm for the past couple of days, and
don't seem to be making any progress on it. I am fairly certain it is a
problem with my understanding of struts, and as such it makes it quite
difficult for me to solve the problem myself.
I am trying to use a textfield a
11 matches
Mail list logo