Thread: DynaActionForm

    #1
  1. PHP & Java Error Master
    Devshed Beginner (1000 - 1499 posts)

    Join Date
    Jun 2003
    Location
    My Computer
    Posts
    1,219
    Rep Power
    0

    DynaActionForm


    I'm looking over this type of ActionForm and it makes it sound like you could add properties "on the fly", but then when I look at what needs to go into the struts-config it's the same thing you'd have in the ActionForm.
    Can you add properties on the fly?

    This article here also seems to imply (but doesnt' directly state that I saw) that you can create a property that doesn't exist already in your struts-config.
    http://struts.apache.org/struts-action/userGuide/building_controller.html
  2. #2
  3. Feelin' Groovy
    Devshed Supreme Being (6500+ posts)

    Join Date
    Aug 2001
    Location
    WDSMIA
    Posts
    10,135
    Rep Power
    5053
    If it's not configured in the struts-config, the ActionServlet won't know which request parameters to bind to the form. You can add properties "on the fly" (e.g., through a RequestProcessor), but it won't happen automatically.

    Do I understand correctly, that you want to parse a collection of Objects from a single request based on a specific parameter naming convention?
    Yawmark
    class Sig{public static void main(String...args){\u0066or(int
    \u0020$:"v\"ʲ\"vΤ\"".to\u0043h\u0061rArray()
    )System./*goto/*$/%\u0126//^\u002A\u002Fout.print((char)(($>>
    +(~'"'&'#'))+('<'>>('\\'/'.')/\u002Array.const(~1)\*\u002F)));}}
  4. #3
  5. PHP & Java Error Master
    Devshed Beginner (1000 - 1499 posts)

    Join Date
    Jun 2003
    Location
    My Computer
    Posts
    1,219
    Rep Power
    0
    Yes. I'd just like to be able to tell the form that I want to add Prop1, Prop2 & Prop3 to the form here, or Prop1, Prop2, Prop3 & Prop4 there.

    Though I'm not sure how/where to create the additional properties.

IMN logo majestic logo threadwatch logo seochat tools logo