Created
December 7, 2022 09:03
-
-
Save MySohoWiki/76c70404d276dac9ac212c7f90ae5665 to your computer and use it in GitHub Desktop.
Get/Set bo fields
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//Get or set BO fields | |
//Instuctions of how to get the dataset follow the link | |
//https://wiki.mysoftwarehouse.gr/docs/enotites/mysoho-ergaleia/customization/mysoho-scripting/business-object-scripting/ | |
// | |
//When you are on frm.CurrentView = fvDetail you can use for set | |
procedure setVals; | |
begin | |
itetrnds.Append; | |
itetrnds.FieldByname('itemid').value:= 12345678; | |
itetrnds.FieldByname('SizeCodeID').value:= 10; | |
itetrnds.FieldByname('ColorCode').value:= 'red'; | |
itetrnds.FieldByname('PriQty').value:= 15; | |
itetrnds.FieldByname('Price').value:= 0; | |
itetrnds.Post; | |
end; | |
//When you are on frm.CurrentView = fvDetail you can use for get. | |
procedure getVals; | |
var | |
iteId:integer; | |
Justification:String; | |
begin | |
iteId:= itetrnds.FieldByname('itemid').value; | |
Justification:= itetrnds.FieldByname('Justification').value; | |
end; | |
//You can find the dataset from the button that expant the classes and functions of script. To view datasets the script must be in running mode. | |
//To find the name of fields just Ctrl+f field you are interesting on form. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment