JSP value beans: am I missing something?

Discussion in 'Java' started by marty mcmahone, Apr 14, 2004.

  1. I'm testing around with building basic beans to use inan HTML form / bean
    combination. I have a set of fields named the same as my instance variables
    and the proper get/set routines. It all works fine, except for the problem
    of non-numeric data. If I have an int instance variable and pass an int
    into the set routine, I get a data exception type crash. OTOH, if I try to
    make the parameter in the set routine a string, then convert it into an int
    (under a try/catch) the set routine is ignored.

    Is there no way to do variable checking in this global method? If not, how
    could this be useful for numeric data?

    Thanks for any insights,

    Marty
     
    marty mcmahone, Apr 14, 2004
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Maxi

    Beans and JSP

    Maxi, Jul 12, 2003, in forum: Java
    Replies:
    1
    Views:
    787
    Andy Flowers
    Jul 12, 2003
  2. Kai Grossjohann

    JSP: Beans from factories?

    Kai Grossjohann, Dec 17, 2003, in forum: Java
    Replies:
    2
    Views:
    710
    Kai Grossjohann
    Dec 17, 2003
  3. GoostleeK
    Replies:
    7
    Views:
    495
    GoostleeK
    Dec 29, 2003
  4. Dan Valero

    Confused about jsp beans and scope

    Dan Valero, Jan 7, 2004, in forum: Java
    Replies:
    1
    Views:
    425
    Gerbrand van Dieijen
    Jan 7, 2004
  5. Torsten Schmeissel
    Replies:
    0
    Views:
    431
    Torsten Schmeissel
    Apr 29, 2005
Loading...

Share This Page