Tips&Tricks
Tips&Tricks
IF ISCLEAR(WshShell) THEN
WshShell.SendKeys(‘{F5}’);
WshShell.SendKeys(‘{F5}’);
4. Functia UpdatePage se apeleaza din trigger-ul corespunzator pentru care se doreste actualizarea
paginii parinte.
StikNotes
ReportTemplateInterface.GetParameter(ReportTemplate."No.",p_TemplateID,1,Data
ItemTableName,SavedDataItemView);
Adresse.SETVIEW(SavedDataItemView);
R5163305.SETTABLEVIEW(Adresse);
ReportTemplateInterface.GetParameter(ReportTemplate."No.",p_TemplateID,2,Data
ItemTableName,SavedDataItemView);
Customer.SETVIEW(SavedDataItemView);
R5163305.SETTABLEVIEW(Customer);
ReportTemplateSI.setLoadOptionsNow(TRUE);
R5163305.USEREQUESTPAGE(TRUE);
R5163305.RUNMODAL;
END;
REPORT HEADER
Globals
Name DataType Subtype Length
Benutzer Record Benutzer newsystem
CSI Codeunit SingleInstance
Gemeinde Record Gemeinde Einrichtung
OnInitReport
Benutzer.GET(CSI.BENUTZERID);
OnPreReport-pt Header
Gemeinde.fn_Get_Gemeinde('','');
LayOut
Companyname =First(Fields!COMPANYNAME.Value, "DataSet_Result")
GemeindeName=First(Fields!Gemeindename.Value, "DataSet_Result")
Pagini=="Seite " & Globals!PageNumber & " von " & Globals!TotalPages
ID==First(Fields!ReportUserID.Value, "DataSet_Result")
UserName=First(Fields!ReportUserName.Value, "DataSet_Result")
Date =Globals!ExecutionTime
TITLE
Globals
OnInitReport
Title := BerichtlisteDrucken.fn_ÜberschriftBericht(Text001);
FILTER
Globals
Name DataType Subtype Length
Filter Text 250
DataItem
Data Type Data Source Name Include Caption
0 Column Filter Filter No
OnPreReport
Filter:= "_____________".GETFILTERS;
REPORT FOOTER
Globals
Name DataType Subtype Length
AktuellerReportID Integer
OnInitReport-pt Footer
EVALUATE(AktuellerReportID,COPYSTR(CurrReport.OBJECTID(FALSE),8));
LayOut
Report id ="ID " & First(Fields!ReportID.Value, "DataSet_Result")
Pentru a putea selecta anumite tabele in functie de un anumit Type, putem folosi
o globala de tip Variant
Pentru exemplu Pg 5093621-ObjektStrukture si subPage-ul 5093683
Basisinformationen FactBox
CULORI
Globals
Name DataType Subtype Length
ReportingMngt Codeunit Reporting Management
PrinterviewSetup Record Reportlayout Setup
DataItem
OnInitReport
ReportingMngt.InitPrinterviewSettings(AktuellerReportID,PrinterviewSetup);
Layout
Pe liniile de detaliu, background color
=iif(RowNumber(Nothing) mod 2 = 1, First(Fields!TabulatedLineColor.Value,
"DataSet_Result"), "None")
Tips
-set field group for dropDown list
-Eg: in TB1 fild F11 with ID 1 is used in onother table, (TB2 for field F21 has
property TableRelation = TB1), so we define in TB1 a field group
id - id of the field
name - action tipe(dropDown, assistEdit, etc.)
Field - the group of field that we want to see in dropDown list
https://msdn.microsoft.com/en-us/library/dd354969(v=nav.71).aspx
=Code.SetData(ReportItems!HeaderData.Value, 1)
Image expresion =code.GetData1(1,1)
Apel
Code.ConvertVal3(FormatNumber(Fields!Betrag_Vorgangsnummer.Value,2),14) - pentru valori
aduse ca decimal
SAU
=Code.SetData(ReportItems!HeaderData.Value, 1)
=Code.SetData(ReportItems!HeaderData.Value)
EXCEL AUTOMATION
-HorizontalAlignment
Left: = -4131
Center: = -4108
Right: = -4152
-VerticalAlignment:
Top: = -4160
Center: =-4108
Bottom: =-4107
Excel color http://dmcritchie.mvps.org/excel/colors.htm
Excel border http://technet.microsoft.com/en-us/library/ee692886.aspx
https://www.youtube.com/watch?v=k22M_RtXq5Q&index=24&list=RDyhXAvglST3
U