PdcTerminal.Process: Difference between revisions

From External Bemet Wiki
Jump to navigation Jump to search
Created page with "== Declaration == Process as Boolean == Description == Changes the stock for the supplied material number. == Notes == This function processes the lines of the terminaltable..."
 
No edit summary
 
(2 intermediate revisions by 2 users not shown)
Line 3: Line 3:


== Description ==
== Description ==
Changes the stock for the supplied material number.
This function processes the lines of the terminaltable.


== Notes ==
== Notes ==
This function processes the lines of the terminaltable for book off or stock changes.
This function processes the lines of the terminaltable for writeoff material or stock changes.<br>
The terminaltable can be filled with a script or with a handterminal. The field TR_MODE contains the kind of stock change.
The terminaltable can be filled with a script or with a handterminal. The field TR_MODE contains the kind of stock change.<br>
1: Material on an existing calculation  
1: Writeoff a material on an existing calculation<br>
2: Stock (and location) change of a material (relatively)  
TR_CALCNR is filled and in production.<br>
3: Stock (and location) change of a material (absolutely)  
TR_MATNR is filled, stock material and not a certificate material (without location management).<br>
4: Location change of a material  
TR_QUANTITY is filled with the writeoff quanitity.<br>
5: Book time on a calculation  
2: Stock (and location) change of a material (relatively)<br>
6: Book materials on a new calculation  
TR_MATNR is filled, stock material and not a certificate material (without location management).<br>
TR_LOCATION is optional.<br>
3: Stock (and location) change of a material (absolutely)<br>
TR_MATNR is filled, stock material and not a certificate material (without location management).<br>
TR_LOCATION is optional.<br>
4: Location change of a material<br>
TR_MATNR is filled, stock material and not a certificate material (without location management).<br>
TR_LOCATION is filled.<br>
5: Book time on a calculation<br>
6: Book materials on a new calculation<br>
TR_MATNR is filled, stock material and not a certificate material (without location management).<br>
7, 8: Writeoff a material on an existing calculation <br>
TR_CALCNR is filled and in production.<br>
TR_DMPOS is filled with an existing pos number of the calculation.<br>
TR_MATNR is filled, stock material and certificate material (with location management).<br>
TR_LMVID is filled with the stockline ID.<br>
TR_INTCRTNR is filled with the certificate number.<br>
TR_QUANTITY is filled with the writeoff quanitity.<br>


== Code example ==
== Code example ==
Line 24: Line 41:
   if IsValid(objTerminal) then
   if IsValid(objTerminal) then
     if not objTerminal.Process then
     if not objTerminal.Process then
  msgbox "Error while processing the Terminal, check TR_LOG for more information."
      msgbox "Error while processing the Terminal, check TR_LOG for more information."
end if
    end if
   end if
   end if
   set objTerminal = nothing
   set objTerminal = nothing

Latest revision as of 14:15, 10 August 2015

Declaration

Process as Boolean

Description

This function processes the lines of the terminaltable.

Notes

This function processes the lines of the terminaltable for writeoff material or stock changes.
The terminaltable can be filled with a script or with a handterminal. The field TR_MODE contains the kind of stock change.
1: Writeoff a material on an existing calculation
TR_CALCNR is filled and in production.
TR_MATNR is filled, stock material and not a certificate material (without location management).
TR_QUANTITY is filled with the writeoff quanitity.
2: Stock (and location) change of a material (relatively)
TR_MATNR is filled, stock material and not a certificate material (without location management).
TR_LOCATION is optional.
3: Stock (and location) change of a material (absolutely)
TR_MATNR is filled, stock material and not a certificate material (without location management).
TR_LOCATION is optional.
4: Location change of a material
TR_MATNR is filled, stock material and not a certificate material (without location management).
TR_LOCATION is filled.
5: Book time on a calculation
6: Book materials on a new calculation
TR_MATNR is filled, stock material and not a certificate material (without location management).
7, 8: Writeoff a material on an existing calculation
TR_CALCNR is filled and in production.
TR_DMPOS is filled with an existing pos number of the calculation.
TR_MATNR is filled, stock material and certificate material (with location management).
TR_LMVID is filled with the stockline ID.
TR_INTCRTNR is filled with the certificate number.
TR_QUANTITY is filled with the writeoff quanitity.

Code example

This code processes the terminaltable.

dim objTerminal

  set objTerminal = pdc.Terminal
  if IsValid(objTerminal) then
    if not objTerminal.Process then
      msgbox "Error while processing the Terminal, check TR_LOG for more information."
    end if
  end if
  set objTerminal = nothing

Availability

Available since version 4.2 onwards.