Accessing Struts Formbean attributes from JSP

Discussion in 'Java' started by Squishy, Jul 3, 2006.

  1. Squishy

    Squishy Guest

    Hello,
    I have a Struts backed JSP. Normally i access the Formbean's parameters
    via Struts Tags like
    <bean:write>.
    However now i have to put some form bean properties into a JSP string

    I tried it this way

    <% mystring = <bean:write name="jslice"
    property="auftragsDatumString"/> %>

    But that didnt work of course.
    How can i access the form bean properties via JSP best?

    Regards
    Holger Johanndeiter
     
    Squishy, Jul 3, 2006
    #1
    1. Advertising

  2. Squishy

    MiSt Guest

    Squishy napisał(a):
    > Hello,
    > I have a Struts backed JSP. Normally i access the Formbean's parameters
    > via Struts Tags like
    > <bean:write>.
    > However now i have to put some form bean properties into a JSP string
    >
    > I tried it this way
    >
    > <% mystring = <bean:write name="jslice"
    > property="auftragsDatumString"/> %>
    >
    > But that didnt work of course.
    > How can i access the form bean properties via JSP best?




    <bean:define id="propertyValueId" name="myFormName"
    property="myFormProperty" />

    <% mystring=properyValueId; %>

    --
    MiSt
     
    MiSt, Jul 3, 2006
    #2
    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. Wendy S
    Replies:
    0
    Views:
    953
    Wendy S
    Jun 28, 2003
  2. Xavier Tarrago
    Replies:
    0
    Views:
    1,440
    Xavier Tarrago
    Jun 30, 2003
  3. Matthias Nietz
    Replies:
    1
    Views:
    3,459
    VisionSet
    Nov 12, 2003
  4. Uwe Voigt
    Replies:
    5
    Views:
    11,956
  5. Eduardo
    Replies:
    4
    Views:
    9,805
    Andrew Thompson
    Sep 19, 2004
Loading...

Share This Page