veyant
5th May 2006, 11:33
Hi,
this is related to BAAN V.

I am creating a Sales Order Splitting AFS in which it starts from tdsls4501m000 (Sales Order Lines) and then invokes (tdsls4101s000), make the Split delivery Flag as "Yes", after pressing details button , it invokes "tdsls4501m200 (Sales Order Lines details)" which invokes "tdsls4101s200" .

In session tdsls4101s200 - total qty is shown and if u click on split detail button, it invokes "tdpur4000s000" where u have to put the qty to be split and after pressing OK, it closes "tdpur4000s000" and changes order qty to bal qty (original order - split qty) and generates a new line with the split qty as seq no. 2

in AFS, it calls tdsls4501m000, invokes tdsls4101s000, then session tdsls4501m200 is invoked with details button and split delivery as "yes", now session tdsls4101s200 gets invoked and it calls "tdpur4000s000".

I am inputting "qty to be split as
stpapi.put.field("tdpur4000s000","ordered.qty", str$(5))
then i am sending a update followed by Save, in save error it gives message ("commnd id disabled".) it ends the session with stpapi.end.session and when it check manually, whether split happened then i found that it doesn't split.

Do anybody help me on this. session "tdpur4000s000" has three fields and 3 buttons.

field 1 - Ordered Qty
field 2 - planned del. date
field 3 - planned del. time

button 1 is "OK" which is basically a save & exit button, then second button is "cancel" and third button is help.

I want to know is there any commend in STPAPI to call "save & exit" button option.

As if send "stpapi.save" it returns with error "command disabled'

need quick help on this.

mark_h
5th May 2006, 14:14
Not sure you need stpapi.update or stpapi.save - Have you tried stpapi.continue? Check to see what the okay button is setup as on the form. Usually on sessions like this the okay button is the same as continue - it processes and closes the session. I am not familiar with these sessions so this is just guess based off your description.

veyant
5th May 2006, 16:34
I have tried bothy stpapi.save and stpapi.continue.process

while using stpapi.save , it returns error "Command is disabled".
on stpapi.continue...., it does nothing.

actually, i checked that OK button is a standard command button which is standard command "Save & Exit".

so can anybody help me in this what should i do to press ok button after putting Ordered.Quantity and del. date as STPAPI.SAVE & STPAPI.CONTINUE.PROCESS both r not working.

does anybody worked on Sales Order Splitting in Baan V

vahdani
8th May 2006, 15:32
Hi,

I used tdsls.dll4101.create.total.line(reason) in one of my Baan V projects. the function return a long value (0 = ok! else error). Parameter reason is also long (0= split shipments or >0 = other reasons). This must be called inside atransaction with the current tdsls401 record selected (not for update!). If ok the position will be split into a total and a detail line. To create subsequent detail lines I use dal.new().

veyant
8th May 2006, 15:38
Can u pls post code for the same. i am not able to understand what u want to convey.

thanks

Danny Leolux
9th May 2006, 14:51
Normaly save and exit would be invoked by
stpapi.update(...)
stpapi.end.session(...)

If the button however is a user.choice there is also the command:
stpapi.application.option(string session, long form, long option, ref string errm)

option should be between 0 and 9 (choice.user.x)

If the session is has a report perhaps the next command can be used:
stpapi.set.report(...)
stpapi.print.report(...)

Hopefully this helps,
Danny

mark_h
9th May 2006, 21:41
I have tried bothy stpapi.save and stpapi.continue.process

while using stpapi.save , it returns error "Command is disabled".
on stpapi.continue...., it does nothing.

actually, i checked that OK button is a standard command button which is standard command "Save & Exit".

so can anybody help me in this what should i do to press ok button after putting Ordered.Quantity and del. date as STPAPI.SAVE & STPAPI.CONTINUE.PROCESS both r not working.

does anybody worked on Sales Order Splitting in Baan V

Just noticed that you say baan V - have you tried stpapi.form.command? I thought this was what you used in Baan V. I am not familiar with the format of this command. Also you may just need the latest stpapi objects or session objects.

I think what vahdani was trying to say is that using DAL functionality in Baan V is (or could be) easier that using the AFS method. It seems several Baan V users have stated that around the board. Since I am not familiar with Baan V I won't be much help.

veyant
10th May 2006, 07:40
thanks everybody,

After putting alot of efforts, i got the error changed, now when i send stpapi.update, followed by stpapi.endsession , it returns back a fatal error : USE of NULL pointer ' '. I searched and found that it is a bug in ttstpstandard and SSA has given a solution 140121 for the same. I am trying to get it installed so that i can test the scenario once again after installation of this solution.


thanks for all the support