Baanboard.com

Go Back   Baanboard.com > Forum > Baan SIGs > AFS/DDC/OLE: Function servers

User login

Frontpage Sponsor

Main

Poll
For ERP LN feature pack upgrade, what method of install are you using?
Installation Wizard into existing VRC
35%
Installation Wizard into new VRC
42%
Manual into existing VRC
3%
Manual into new VRC
19%
Total votes: 31

Baanboard at LinkedIn


Reference Content

Reply
 
Thread Tools Display Modes
  #1  
Old 26th August 2010, 15:56
coolbaan coolbaan is offline
Junior Member
 
Join Date: Nov 2006
Posts: 7
coolbaan is on a distinguished road
Baan: Baan 4c4 , LN 6.1 - DB: SQL - SERVER 2000 - OS: Win NT
afs sale order Line problem

Hi all,
Please help me in sale order line session its does not get handle properly
problem in putting line data sale order Line data session does not got handle properly.
I m creating new sales return order of already prepare Sale order
Its Urgent Yaar


its prepare Header Properly .
sales order Line session Does get Handle with support of Header.
its run Indepently.


Code:
declaration:

table ttdsls040 | Sales Orders
table ttdind013
table ttdind017
table ttdsls041

extern domain tcorno orno.f,orno,orno1
extern domain tcorno orno.t
extern domain tcpono pon,pono1
extern domain tcnama cuno.nama
extern domain tcdsca cpls.dsca
extern domain tcdsca pldd.dsca
extern domain tcnama pcpr.nama
extern domain tcnama pctx.nama
extern domain tcmcs.str100 err.msg
extern domain tcmcs.str6 ordno
extern domain tcmcs.str50 code
extern string series(2),pono(2)
long ret
#pragma used dll ottstpapihand
#pragma used dll ottdllbw
#pragma nowarnings
|****************************** form section **********************************

form.1:
init.form:
get.screen.defaults()

|****************************** choice section ********************************

choice.cont.process:
on.choice:
execute(print.data)

choice.print.data:
on.choice:
if rprt_open() then
read.main.table()
rprt_close()
else
choice.again()
endif


|****************************** field section *********************************

field.orno.f:
when.field.changes:
orno.t = orno.f


|****************************** function section ******************************

functions:

function read.main.table()
{
select tdsls040.ornorno,tdsls040.*
from tdsls040
where tdsls040._index1 inrange {rno.f}
and {rno.t}
order by tdsls040._index1
selectdo
series=str$(tdsls040.orno)
stpapi.put.field("tdsls4101m000", "tdsls040.orno", series)
stpapi.put.field("tdsls4101m000", "tdsls040.cuno", tdsls040.cuno)
stpapi.put.field("tdsls4101m000", "tdsls040.cotp", str$("DN1"))
stpapi.put.field("tdsls4101m000", "tdsls040.refa", str$(orno))
stpapi.put.field("tdsls4101m000", "tdsls040.refb", str$("Test SalesOrder"))
stpapi.put.field("tdsls4101m000", "tdsls040.prdt", str$(date.num()))
stpapi.put.field("tdsls4101m000", "tdsls040.ddat", str$(date.num()))
stpapi.put.field("tdsls4101m000", "tdsls040.odis", str$(tdsls040.odis))
stpapi.put.field("tdsls4101m000", "tdsls040.ccor", tdsls040.ccor)
stpapi.put.field("tdsls4101m000", "tdsls040.cdel", tdsls040.cdel)
stpapi.put.field("tdsls4101m000", "tdsls040.cpay", tdsls040.cpay)
stpapi.insert("tdsls4101m000",true,err.msg)
if isspace(err.msg) then
stpapi.get.field("tdsls4101m000","tdsls040.orno",ordno)
stpapi.handle.subproc("tdsls4101m000","tdsls4102s000","add") |problem facing
stpapi.continue.process("tdsls4101m000",err.msg) |problem facing
select tdsls041.*,tdsls041.ponoon
from tdsls041
where tdsls041._index1={rno}
selectdo
endselect
stpapi.put.field("tdsls4102s000","tdsls041.item",tdsls041.item)
stpapi.put.field("tdsls4102s000","tdsls041.cntr",tdsls041.cntr)
stpapi.put.field("tdsls4102s000","tdsls041.cwar",tdsls041.cwar)
stpapi.put.field("tdsls4102s000","tdsls041.oqua",str$(tdsls041.oqua))
stpapi.put.field("tdsls4102s000","tdsls041.drct",str$(etol(tdsls041.drct)))
stpapi.put.field("tdsls4102s000","tdsls041.pric",str$(tdsls041.pric))
stpapi.handle.subproc("tdsls4102s000","mtdsls000090451","10")
stpapi.insert("tdsls4102s000",true,err.msg)
stpapi.save("tdsls4102s000",err.msg)
if isspace(err.msg) then
else
message("Error in Sales order,%s Line",err.msg)
code=err.msg
stpapi.end.session("tdsls4102s000")
stpapi.end.session("tdsls4101m000")
end()
endif
endif
endselect
}





Regards,
cool baan

Last edited by mark_h : 26th August 2010 at 17:13.
Reply With Quote
  #2  
Old 26th August 2010, 17:32
mark_h's Avatar
mark_h mark_h is offline
Guru
 
Join Date: Sep 2001
Location: Kentucky, USA
Posts: 6,905
mark_h will become famous soon enough
Baan: Baan 4C4 A&D1 - DB: Oracle - OS: Sun Solaris
Okay - this is the correct forum about AFS. I recommend searching the forum for the sessions in question. Are you doing this in 4c4 or ln?

See these threads for some examplesThread 1 or thread 2. When you do this manually how do you activate the tdsls4102s000 session from tdsls4101m000? Is it by clicking continue in tdsls4101m000? A lot of the threads mention a menu. If that is the case then to get from 4101m000 to 4102s000 you need to activate the menu correctly.
__________________
Mark

GO Cards!
My latest mantra - make sure you have latest stpapi patches and the latest session object. If on LN then please explore the option of using DAL2 functionality.

Shared Solutions for Baan systems provided free by Baan Board.
Play the Google game and help Baanboard get better rankings. Do your part. Click here to find how.
Reply With Quote
Sponsored Links
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Report with output with more than 255 char. Jaap Roos Tools Development 5 9th February 2007 21:37
problem in AFS - Sales Order Splitting veyant AFS/DDC/OLE: Function servers 7 10th May 2006 06:40
Problem: Push production order from "To be completed" to "Complete". mostrightfuture Manufacturing & Supply Chain 3 27th April 2006 04:33
AFS : Create a sales Order Line for a Generic Item van_math AFS/DDC/OLE: Function servers 2 1st June 2004 14:32
Problem: increment of purchase receipt line tbrault Distribution, Transportation & Warehousing 5 3rd July 2002 09:20


All times are GMT +2. The time now is 14:58.


©2001-2017 - Baanboard.com - Baanforums.com