The BEASGUI supports the expansion of SAP Business One windows.
To add e.g. new buttons or fields can be deposited for each FormType a source file with BEASSCRIPT.
The file is set in the program path or the project path, and the file name must have the following format:
sbo_xxx.src … xxx corresponds to the SAP Business One specific FormType
The FormType can be determined, if in the SAP Business One the debug mode is activated and the corresponding window is opened.
In the status bar will be displayed the appropriate FormType, if the mouse pointer is over the form.
beasguievents are ONLY executed for pure SAP Forms.
BEAS windows in the SAP environment have their own events (see Userevents / Systemevents).
The following events can be defined:
Each event has a Preevent.
Does the Preevent returns a Success, though the SAP standard and all following AddOns are ignored.
Example: Click on OK button.
It is used the preitempressed-Event.
windowevent preitempressed 1
if <currentuser> = "olli" then
// cancel Update
return false
end if
return no_action
BEAS inserts already several scripts.
These may not be deleted or changed.
If a project directory is activated, so custom-made extensions can be inserted.
The extensions will be executed here AFTER the BEAS-script.
If the command "OVERWRITE" is inserted, the BEAS-script is "overwritten" and there will be only used the custome-made script.
The custom-made script is executed BEFORE the system script.
ATTENTION: If a "return" was inserted, so the system specific script will NOT more be executed.
Begins the custom-made script with "EXTENSION", so the custome-made script will be executed AFTER the system script.
If the system script ends with a RETURN, however, the custome-made script will not be executed, because it will be simply appended.
For example (in extended scripts):
The print icon should have default behavior as in SAP.
All form events will only be called, if you are NOT in preview or search mode !
Not affected from it, are e.g. application menu and menu events.
windowevent print
overwrite
return NO_ACTION
open "view" - "System-Informatino"
insert in "Filter" "windowevent" (do not click on Button "Filter"!)
now you can see all Filter, which triggered from SAP to be.as
Example: change quantity in sales quotation (Grid 38, Coll 11)
windowevent itemchanged 38 11
messagebox=new item=<item=38.col.1.value>, new Qty: <item=38.col.11.value>
end event
Example for right click: see Example in Create Right Click Entry