santana
17th August 2005, 14:38
Hi all, i am triyng to create baan clients ( tccom010 ) whith VB aplication using this function in baan DLL:
All of them return 0 but the client is not inserted in the table, can anynone give me a clue ?
Thanks
PS - Bellow the Baan DLL called
function extern void tccom1101m000f.put.cliente( const domain tccuno vcuno, const domain tcnama vnama,
const domain tcnamc vnamc,const domain tcpstc vpstc,const domain tcccty vccty,
const domain tctelp vtelp,const domain tctelx vtelx)
{
DLLUSAGE
Function to set Customer, name and other required and user definable fields
ENDDLLUSAGE
stpapi.put.field( "tccom1101m000", "tccom010.cuno", vcuno )
stpapi.put.field( "tccom1101m000", "tccom010.nama", vnama )
stpapi.put.field( "tccom1101m000", "tccom010.namc", vnamc )
stpapi.put.field( "tccom1101m000", "tccom010.pstc", vpstc )
stpapi.put.field( "tccom1101m000", "tccom010.ccty", vccty )
stpapi.put.field( "tccom1101m000", "tccom010.telp", vtelp )
stpapi.put.field( "tccom1101m000", "tccom010.telx", vtelx )
}
function extern void tccom1101m000f.put.cliente_def( )
{
DLLUSAGE
Function to set Customer default data for non inputable fields
ENDDLLUSAGE
stpapi.put.field( "tccom1101m000", "tccom010.comp", "941" )
stpapi.put.field( "tccom1101m000", "tccom010.crep", "0" )
stpapi.put.field( "tccom1101m000", "tccom010.clan", "PT" )
stpapi.put.field( "tccom1101m000", "tccom010.ccur", "EUR" )
stpapi.put.field( "tccom1101m000", "tccom010.cvyn", "2" )
stpapi.put.field( "tccom1101m000", "tccom010.crlr", "0" )
stpapi.put.field( "tccom1101m000", "tccom010.clin", "0" )
stpapi.put.field( "tccom1101m000", "tccom010.eded", "0" )
stpapi.put.field( "tccom1101m000", "tccom010.cnpa", "1" )
stpapi.put.field( "tccom1101m000", "tccom010.itpr", "2" )
stpapi.put.field( "tccom1101m000", "tccom010.ncin", "0" )
stpapi.put.field( "tccom1101m000", "tccom010.lidt", "0" )
stpapi.put.field( "tccom1101m000", "tccom010.back", "1" )
stpapi.put.field( "tccom1101m000", "tccom010.scom", "2" )
stpapi.put.field( "tccom1101m000", "tccom010.cfcg", "001" )
stpapi.put.field( "tccom1101m000", "tccom010.odis", "0" )
stpapi.put.field( "tccom1101m000", "tccom010.prio", "99" )
stpapi.put.field( "tccom1101m000", "tccom010.ackx", "2" )
stpapi.put.field( "tccom1101m000", "tccom010.ccra", "0" )
}
function extern long tccom1101m000f.insert( long do.update, ref string error )
{
DLLUSAGE
Function to insert a record in session tccom1101m000
Fields must be put before calling this function
ENDDLLUSAGE
return( stpapi.insert( "tccom1101m000", do.update, error ) )
}
function extern long tccom1101m000f.save( ref string error )
{
DLLUSAGE
Function to save an update/insert/delete in session tccom1101m000
ENDDLLUSAGE
return( stpapi.save( "tccom1101m000", error ) )
}
function extern void tccom1101m000f.end([string error(500)])
{
DLLUSAGE
Function to end connection to session tccom1101m000
ENDDLLUSAGE
if get.argc() = 0 then
stpapi.end.session( "tccom1101m000" )
else
error = get.string.arg(1)
stpapi.end.session( "tccom1101m000" , error )
put.string.arg(1, error)
endif
All of them return 0 but the client is not inserted in the table, can anynone give me a clue ?
Thanks
PS - Bellow the Baan DLL called
function extern void tccom1101m000f.put.cliente( const domain tccuno vcuno, const domain tcnama vnama,
const domain tcnamc vnamc,const domain tcpstc vpstc,const domain tcccty vccty,
const domain tctelp vtelp,const domain tctelx vtelx)
{
DLLUSAGE
Function to set Customer, name and other required and user definable fields
ENDDLLUSAGE
stpapi.put.field( "tccom1101m000", "tccom010.cuno", vcuno )
stpapi.put.field( "tccom1101m000", "tccom010.nama", vnama )
stpapi.put.field( "tccom1101m000", "tccom010.namc", vnamc )
stpapi.put.field( "tccom1101m000", "tccom010.pstc", vpstc )
stpapi.put.field( "tccom1101m000", "tccom010.ccty", vccty )
stpapi.put.field( "tccom1101m000", "tccom010.telp", vtelp )
stpapi.put.field( "tccom1101m000", "tccom010.telx", vtelx )
}
function extern void tccom1101m000f.put.cliente_def( )
{
DLLUSAGE
Function to set Customer default data for non inputable fields
ENDDLLUSAGE
stpapi.put.field( "tccom1101m000", "tccom010.comp", "941" )
stpapi.put.field( "tccom1101m000", "tccom010.crep", "0" )
stpapi.put.field( "tccom1101m000", "tccom010.clan", "PT" )
stpapi.put.field( "tccom1101m000", "tccom010.ccur", "EUR" )
stpapi.put.field( "tccom1101m000", "tccom010.cvyn", "2" )
stpapi.put.field( "tccom1101m000", "tccom010.crlr", "0" )
stpapi.put.field( "tccom1101m000", "tccom010.clin", "0" )
stpapi.put.field( "tccom1101m000", "tccom010.eded", "0" )
stpapi.put.field( "tccom1101m000", "tccom010.cnpa", "1" )
stpapi.put.field( "tccom1101m000", "tccom010.itpr", "2" )
stpapi.put.field( "tccom1101m000", "tccom010.ncin", "0" )
stpapi.put.field( "tccom1101m000", "tccom010.lidt", "0" )
stpapi.put.field( "tccom1101m000", "tccom010.back", "1" )
stpapi.put.field( "tccom1101m000", "tccom010.scom", "2" )
stpapi.put.field( "tccom1101m000", "tccom010.cfcg", "001" )
stpapi.put.field( "tccom1101m000", "tccom010.odis", "0" )
stpapi.put.field( "tccom1101m000", "tccom010.prio", "99" )
stpapi.put.field( "tccom1101m000", "tccom010.ackx", "2" )
stpapi.put.field( "tccom1101m000", "tccom010.ccra", "0" )
}
function extern long tccom1101m000f.insert( long do.update, ref string error )
{
DLLUSAGE
Function to insert a record in session tccom1101m000
Fields must be put before calling this function
ENDDLLUSAGE
return( stpapi.insert( "tccom1101m000", do.update, error ) )
}
function extern long tccom1101m000f.save( ref string error )
{
DLLUSAGE
Function to save an update/insert/delete in session tccom1101m000
ENDDLLUSAGE
return( stpapi.save( "tccom1101m000", error ) )
}
function extern void tccom1101m000f.end([string error(500)])
{
DLLUSAGE
Function to end connection to session tccom1101m000
ENDDLLUSAGE
if get.argc() = 0 then
stpapi.end.session( "tccom1101m000" )
else
error = get.string.arg(1)
stpapi.end.session( "tccom1101m000" , error )
put.string.arg(1, error)
endif