outra9e
14th January 2002, 11:03
Hi guys
I am looking to develop a second form for sales orders to have information entered.
However it is to be for a new table that I shall be creating.
How do I go about this?
Do I create table definitions, create table generate sessions and then link the relevant forms together? If so how do I link the forms?
Or is there another way that I should be doing this?
Any help guys would be great!
Cheers
MariaC
14th January 2002, 13:14
If all you are wanting to do is add a new form to a session then there is no need to run Generate Sessions. The easiest would probably be to copy the existing form to a new name, add the new form to the session by clicking on the Forms button on the Maintain Sessions (form 1) and entering your new form name. Then go to Maintain Sessions (form 2) and edit your form. You would also need to adjust the Form Options for both forms.
This applies to BaanIV.
outra9e
14th January 2002, 13:44
Ok as an alternative how easy would it be, to create the table generate the sessions and then on the Sales Order, when a value = 0 the session for the new table is fired up?
MariaC
14th January 2002, 14:52
That is an option, you would then have to create the session as a subsession. The only thing to remember if you're going to do it this way is whether the user must always fill this information in for a new sales order, if so then you'll have to decide on how you're going to force this to happen.
evesely
14th January 2002, 16:03
If you are going to do it as a subsession, you will need to actually call that subsession. In this case, since you want it to be called when a value = 0, you will need to do it through scripting. You can either customize the sales order program script or use the utility that ~Vamsi created as a starting point for "wrapping" the sales order program script (see DEV: Extend Baan code without sources (http://www.baanboard.com/baanboard/showthread.php?s=&threadid=559) )
You could collect the values by just adding another form to the session, but you would still need to write some code to tell Baan to save the data since it isn't on the main table.
My personal preference would be calling the subsession; it seems to be cleaner. Others will probably feel differently...:D
outra9e
21st January 2002, 18:44
So guys
I create the table and generate sessions, specifying as subsessions.
Now I have never created a subsession, does BaaN ask where the session is to derive from?
I am guessing that once I have created the subseesion I add the form for the maintain session to the original session, therefore making the input of the data part of the original process.
It could be a possibility that the information input of the new form does not have to forced as the user will be running the process to fill in that information.
If that is the case, then what is stated above should suffice and be sufficient?
Cheers