Line 1: | Line 1: | ||
==Introduction== | ==Introduction== | ||
In Fast Report there is no such function call '''Shit Relative To'''. This only available in | In Fast Report there is no such function call '''Shit Relative To'''. This only available in Report Builder. So to simulate this function we had created the below script. | ||
==Requirement== | ==Requirement== |
Revision as of 03:22, 26 November 2015
Introduction
In Fast Report there is no such function call Shit Relative To. This only available in Report Builder. So to simulate this function we had created the below script.
Requirement
- Fast Report
- SQL Accounting Version 721 & above
Steps
Below is example using Sales Invoice
- 01. Place all the component (eg TfrxMemoView or TfrxRichView) as following
- 02. Only TfrxMemoView component need to select Dataset & DataField
- 03. For TfrxRichView component must leave it empty for Dataset & DataField
- 04. For TfrxRichView double click & select the ABC icon & select the Data Field
- 05. Click Tick icon after select the Field
- 06. On each component(i.e. MmDesc, RichDesc3 & RichSN) set all the GapY to 0
- 07. Click on the Empty place (see icon 1 below)
- 08. Double click OnBeforePrint (see icon 2 above)
- 09. Enter below script
procedure Page1OnBeforePrint(Sender: TfrxComponent);
begin
//For Version 721 & above
ShiftRelative([MmDesc, RichDesc3, RichSN]); // ShiftRelative([ComponentName1, ComponentName2, ComponentName3]) // For DetailData1
ShiftRelative([MmDescM, RichDesc3M]); // For DetailData2
end;
- 10. Save the Report.
- ----------------------------------------------------------------------------------------------------------------------------------------------------
- ----------------------------------------------------------------------------------------------------------------------------------------------------
Video
FAQ
01. Why it overlap when preview even at design time no overlap?
- If preview shown something like below, try adjust the component to by add 0.01 for Top field
02. Why it still same even after all the step above had follow & all scripts had copy?
- Make sure the compoents width not overlap to next field
03. Can my 2nd & 3rd field longer then 1st field?
- Yes just tick the Shift When Overlapped option in right click for both 2nd & 3rd compoent
See also
- Report Designer
- Others Customisation