Hey Wouter, Did you mean an incoming transition (when you said outgoing below)?
I have currently adding an incoming transition to the FrontEndView called Display User List. I had not given any name to it based on the example from the animal quiz which is the transition from "prompt the user" to "answer question" (where the question is being sent to "answer question"). Should I give it a name? I have added a param userList to this transition and given it a data type of Collection. This param by default has the following tags: @andromda.struts.view.field.format : String[*] @andromda.struts.view.field.required : String[*] In MagicDraw, I couldn't figure out how to add @andromda.struts.view.field.type = select When I click on Edit Tag Definitions and the on the Add button I see a "Select Extension Element Storage" popup. What do I need to select there? Thanks, Sunondo -----Original Message----- From: Wouter Zoons [mailto:[EMAIL PROTECTED] Sent: Monday, June 14, 2004 1:17 PM To: Sunondo Ghosh Cc: Chad Brandon; [EMAIL PROTECTED] Subject: Re: [Andromda-user] RE: Creating tables using Hypersonic for AnimalQuiz thanks Sunondo! I can already give you a tip for displaying a list of users: 1. on the action state representing the page you must have an outgoing transition 2. add a trigger to this transition and give it a good name 3. add a parameter (or more) to this trigger, let's say "users" which is a collection (or array) instance 4. add a tagged value to that parameter: @andromda.struts.view.field.type = select this should render a list allowing multiple selections, the action form will contain a variable "usersBackingList" that contains the complete list of users; there will be another variable "users" that represents the collection of selected users (always a subset of the backing list) if you prefer a combobox instead of a list you can just change the type of the "users" variable to a non-collection object (you probably want to rename to "user" too) that's all you need to do, just make sure the rest of the activity graph is correct too, soon the cartridge will help you there :-) hth -- Wouter Sunondo Ghosh wrote: >Thank you, that worked. I now have a working example where I can create >a new user using the generated code. Thanks to you and Wouter for all >your help. This is really cool stuff! > >Now I will try to add more action states to the activity diagram. I need >to display the list of users created by the previous steps. Let's see >how that goes. :-) > >Sunondo > >-----Original Message----- >From: Chad Brandon [mailto:[EMAIL PROTECTED] >Sent: Monday, June 14, 2004 5:42 AM >To: Sunondo Ghosh >Cc: [EMAIL PROTECTED] >Subject: Re: Creating tables using Hypersonic for AnimalQuiz > >Hi Sundondo, > >This is probably because your HSSQL ds.xml file needs >to have the following things uncommented: > > <!-- for tcp connection, allowing other >processes to use the hsqldb > database. This requires the >org.jboss.jdbc.HypersonicDatabase mbean. > ><connection-url>jdbc:hsqldb:hsql://localhost:1701</connection-url> >--> > >and: > > > <!-- This mbean should be used only when using tcp >connections. Uncomment > when the tcp based connection-url is used. > <mbean code="org.jboss.jdbc.HypersonicDatabase" > name="jboss:service=Hypersonic"> > <attribute name="Port">1701</attribute> > <attribute name="Silent">true</attribute> > <attribute name="Database">default</attribute> > <attribute name="Trace">false</attribute> > <attribute name="No_system_exit">true</attribute> > </mbean> > --> > >So uncomment those things and it should work. > >Chad > >--- Sunondo Ghosh <[EMAIL PROTECTED]> wrote: > > >>Hi Chad, >> >>I have a question about creating the tables used in >>the AnimalQuiz sample. When I run the >>initializeSchema then I get the error included at >>the bottom of my email. I looked in my JBoss deploy >>dir and saw the hsqldb-ds.xml config file. I >>modified the connection url there but then jboss >>startup threw some exceptions. Do you know what I >>need to do to set up hsqldb in order to create the >>tables? I went to the hsqldb site on sourceforge but >>didn't find much info there. >> >>In the older version of Andromda (2.x) the tables >>were getting created automatically. However in the >>new version it complains while trying to create a >>new entity that the table does not exist. Am I doing >>something wrong in the new version? >> >>Thanks for your help, >> >>Sunondo >> >> >> >> >C:\andromda-bin-3.0M1\samples\animal-quiz\app\target>java > > >>-classpath C:\jboss-3. >>2.3\server\default\lib\hsqldb.jar >>org.hsqldb.util.ScriptTool -driver org.hsqldb. >>jdbcDriver -url jdbc:hsqldb:hsql: -database >>//localhost:1701 -script hibernate-s >>chema-initialize.sql >>ScriptTool.init error: Connection is broken: >>Connection refused: connect >>java.sql.SQLException: Connection is broken: >>Connection refused: connect >> at org.hsqldb.Trace.getError(Unknown Source) >> at org.hsqldb.Trace.error(Unknown Source) >> at >>org.hsqldb.jdbcConnection.reconnectHSQL(Unknown >>Source) >> at >>org.hsqldb.jdbcConnection.openHSQL(Unknown Source) >> at org.hsqldb.jdbcConnection.<init>(Unknown >>Source) >> >> >> >> ------------------------------------------------------- This SF.Net email is sponsored by The 2004 JavaOne(SM) Conference Learn from the experts at JavaOne(SM), Sun's Worldwide Java Developer Conference, June 28 - July 1 at the Moscone Center in San Francisco, CA REGISTER AND SAVE! http://java.sun.com/javaone/sf Priority Code NWMGYKND _______________________________________________ Andromda-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/andromda-user
