OBJECT Report 90000 Sales Orders { OBJECT-PROPERTIES { Date=08/03/11; Time=[ 9:53:12 PM]; Modified=Yes; Version List=; } PROPERTIES { } DATAITEMS { { PROPERTIES { DataItemTable=Table36; DataItemTableView=SORTING(Document Type,No.) WHERE(Document Type=CONST(Order)); NewPagePerRecord=Yes; ReqFilterFields=No.; } SECTIONS { } } { PROPERTIES { DataItemIndent=1; DataItemTable=Table2000000026; DataItemTableView=SORTING(Number) WHERE(Number=FILTER(1..)); NewPagePerRecord=Yes; DataItemVarName=Copy Loop; OnPreDataItem=BEGIN IF NoOfLoops <= 0 THEN NoOfLoops := 1; SETRANGE(Number,1,NoOfLoops); IF ISSERVICETIER THEN OutputNo := NoOfLoops; END; OnAfterGetRecord=BEGIN IF Number > 1 THEN BEGIN IF ISSERVICETIER THEN OutputNo += 1; END; CurrReport.PAGENO := 1; END; } SECTIONS { } } { PROPERTIES { DataItemIndent=2; DataItemTable=Table2000000026; DataItemTableView=SORTING(Number) WHERE(Number=CONST(1)); DataItemVarName=Page Loop; } SECTIONS { { PROPERTIES { SectionType=Header; SectionWidth=18150; SectionHeight=846; } CONTROLS { { 1000000008;TextBox;3150 ;0 ;1500 ;423 ;HorzAlign=Left; SourceExpr="Sales Header"."No."; DataSetFieldName=Sales_Header___No__ } { 1000000009;Label ;0 ;0 ;3000 ;423 ;ParentControl=1000000008; DataSetFieldName=Sales_Header___No__Caption } { 1000000001;TextBox;0 ;423 ;1500 ;423 ;SourceExpr=OutputNo; DataSetFieldName=OutputNo } } } } } { PROPERTIES { DataItemIndent=3; DataItemTable=Table37; DataItemTableView=SORTING(Document Type,Document No.,Line No.); DataItemLinkReference=Sales Header; DataItemLink=Document Type=FIELD(Document Type), Document No.=FIELD(No.); } SECTIONS { { PROPERTIES { SectionType=Header; SectionWidth=18150; SectionHeight=846; } CONTROLS { { 1000000007;Label ;4650 ;0 ;1500 ;846 ;ParentControl=1000000000; VertAlign=Bottom; FontBold=Yes; MultiLine=Yes; DataSetFieldName=Sales_Line__No__Caption } { 1000000011;Label ;6300 ;0 ;4500 ;846 ;ParentControl=1000000010; VertAlign=Bottom; FontBold=Yes; MultiLine=Yes; DataSetFieldName=Sales_Line_DescriptionCaption } } } { PROPERTIES { SectionType=Body; SectionWidth=18150; SectionHeight=423; } CONTROLS { { 1000000000;TextBox;4650 ;0 ;1500 ;423 ;SourceExpr="No."; DataSetFieldName=Sales_Line__No__ } { 1000000010;TextBox;6300 ;0 ;4500 ;423 ;SourceExpr=Description; DataSetFieldName=Sales_Line_Description } } } } } } REQUESTFORM { PROPERTIES { Width=9020; Height=3410; } CONTROLS { { 1000000000;TextBox;3520 ;220 ;1700 ;440 ;InPage=-1; SourceExpr=NoOfLoops } { 1000000001;Label ;110 ;220 ;3300 ;440 ;ParentControl=1000000000 } } } REQUESTPAGE { PROPERTIES { } CONTROLS { { 1000000000;;Container; ContainerType=ContentArea } { 1000000001;1;Group ; CaptionML=ENU=Options; GroupType=Group } { 1000000002;2;Field ; Name=No. Of Copies; SourceExpr=NoOfLoops } } } CODE { VAR OutputNo@1000000000 : Integer; NoOfLoops@1000000001 : Integer; BEGIN END. } RDLDATA { <?xml version="1.0" encoding="utf-8"?> <Report xmlns="http://schemas.microsoft.com/sqlserver/reporting/2005/01/reportdefinition" xmlns:rd="http://schemas.microsoft.com/SQLServer/reporting/reportdesigner"> <Body> <Height>1.90476cm</Height> <ReportItems> <List Name="list1"> <DataSetName>DataSet_Result</DataSetName> <Grouping Name="list1_Details_Group"> <GroupExpressions> <GroupExpression>=Fields!Sales_Header___No__.Value</GroupExpression> <GroupExpression>=Fields!OutputNo.Value</GroupExpression> </GroupExpressions> <PageBreakAtEnd>true</PageBreakAtEnd> </Grouping> <ReportItems> <Table Name="Table1"> <DataSetName>DataSet_Result</DataSetName> <Details> <TableRows> <TableRow> <Height>0.42328cm</Height> <TableCells> <TableCell> <ReportItems> <Textbox Name="Sales_Line__No__"> <Style> <FontSize>7pt</FontSize> <PaddingBottom>2pt</PaddingBottom> <PaddingLeft>2pt</PaddingLeft> <PaddingRight>2pt</PaddingRight> <PaddingTop>2pt</PaddingTop> <VerticalAlign>Middle</VerticalAlign> </Style> <Value>=Fields!Sales_Line__No__.Value</Value> </Textbox> </ReportItems> </TableCell> <TableCell> <ReportItems> <Textbox Name="Sales_Line_Description"> <Style> <FontSize>7pt</FontSize> <PaddingBottom>2pt</PaddingBottom> <PaddingLeft>2pt</PaddingLeft> <PaddingRight>2pt</PaddingRight> <PaddingTop>2pt</PaddingTop> <VerticalAlign>Middle</VerticalAlign> </Style> <Value>=Fields!Sales_Line_Description.Value</Value> </Textbox> </ReportItems> </TableCell> </TableCells> </TableRow> </TableRows> </Details> <Header> <TableRows> <TableRow> <Height>0.84656cm</Height> <TableCells> <TableCell> <ReportItems> <Textbox Name="Sales_Line__No__Caption"> <CanGrow>true</CanGrow> <Style> <FontSize>7pt</FontSize> <FontWeight>700</FontWeight> <PaddingBottom>2pt</PaddingBottom> <PaddingLeft>2pt</PaddingLeft> <PaddingRight>2pt</PaddingRight> <PaddingTop>2pt</PaddingTop> <VerticalAlign>Bottom</VerticalAlign> </Style> <Value>=First(Fields!Sales_Line__No__Caption.Value)</Value> </Textbox> </ReportItems> </TableCell> <TableCell> <ReportItems> <Textbox Name="Sales_Line_DescriptionCaption"> <CanGrow>true</CanGrow> <Style> <FontSize>7pt</FontSize> <FontWeight>700</FontWeight> <PaddingBottom>2pt</PaddingBottom> <PaddingLeft>2pt</PaddingLeft> <PaddingRight>2pt</PaddingRight> <PaddingTop>2pt</PaddingTop> <VerticalAlign>Bottom</VerticalAlign> </Style> <Value>=First(Fields!Sales_Line_DescriptionCaption.Value)</Value> </Textbox> </ReportItems> </TableCell> </TableCells> </TableRow> </TableRows> </Header> <Height>1.26984cm</Height> <Left>0.125in</Left> <TableColumns> <TableColumn> <Width>4.52381cm</Width> </TableColumn> <TableColumn> <Width>13.57143cm</Width> </TableColumn> </TableColumns> <Top>0.31746cm</Top> <Width>7.125in</Width> </Table> </ReportItems> <Sorting> <SortBy> <Direction>Ascending</Direction> <SortExpression>=Fields!Sales_Header___No__.Value</SortExpression> </SortBy> <SortBy> <Direction>Ascending</Direction> <SortExpression>=Fields!Sales_Line__No__.Value</SortExpression> </SortBy> </Sorting> <Width>7.375in</Width> </List> </ReportItems> </Body> <BottomMargin>2cm</BottomMargin> <Code>Public Function BlankZero(ByVal Value As Decimal) if Value = 0 then Return "" end if Return Value End Function Public Function BlankPos(ByVal Value As Decimal) if Value > 0 then Return "" end if Return Value End Function Public Function BlankZeroAndPos(ByVal Value As Decimal) if Value >= 0 then Return "" end if Return Value End Function Public Function BlankNeg(ByVal Value As Decimal) if Value < 0 then Return "" end if Return Value End Function Public Function BlankNegAndZero(ByVal Value As Decimal) if Value <= 0 then Return "" end if Return Value End Function </Code> <DataSets> <DataSet Name="DataSet_Result"> <Fields> <Field Name="Sales_Header_Document_Type"> <DataField>Sales_Header_Document_Type</DataField> </Field> <Field Name="Sales_Header_No_"> <DataField>Sales_Header_No_</DataField> </Field> <Field Name="Sales_Header___No__"> <DataField>Sales_Header___No__</DataField> </Field> <Field Name="Sales_Header___No__Caption"> <DataField>Sales_Header___No__Caption</DataField> </Field> <Field Name="OutputNo"> <DataField>OutputNo</DataField> </Field> <Field Name="Sales_Line__No__Caption"> <DataField>Sales_Line__No__Caption</DataField> </Field> <Field Name="Sales_Line_DescriptionCaption"> <DataField>Sales_Line_DescriptionCaption</DataField> </Field> <Field Name="Sales_Line__No__"> <DataField>Sales_Line__No__</DataField> </Field> <Field Name="Sales_Line_Description"> <DataField>Sales_Line_Description</DataField> </Field> <Field Name="Sales_Line_Document_Type"> <DataField>Sales_Line_Document_Type</DataField> </Field> <Field Name="Sales_Line_Document_No_"> <DataField>Sales_Line_Document_No_</DataField> </Field> <Field Name="Sales_Line_Line_No_"> <DataField>Sales_Line_Line_No_</DataField> </Field> </Fields> <Query> <CommandText /> <DataSourceName>DummyDataSource</DataSourceName> </Query> <rd:DataSetInfo> <rd:DataSetName>DataSet</rd:DataSetName> <rd:TableName>Result</rd:TableName> </rd:DataSetInfo> </DataSet> </DataSets> <DataSources> <DataSource Name="DummyDataSource"> <ConnectionProperties> <ConnectString /> <DataProvider>SQL</DataProvider> </ConnectionProperties> <rd:DataSourceID>766773c0-510c-438c-8cc3-aa402016a9a0</rd:DataSourceID> </DataSource> </DataSources> <InteractiveHeight>11.69in</InteractiveHeight> <InteractiveWidth>8.27in</InteractiveWidth> <Language>=User!Language</Language> <LeftMargin>2.1cm</LeftMargin> <PageHeader> <Height>0.25in</Height> <PrintOnFirstPage>true</PrintOnFirstPage> <PrintOnLastPage>true</PrintOnLastPage> <ReportItems> <Textbox Name="textbox1"> <CanGrow>true</CanGrow> <Left>0.125in</Left> <Style> <PaddingBottom>2pt</PaddingBottom> <PaddingLeft>2pt</PaddingLeft> <PaddingRight>2pt</PaddingRight> <PaddingTop>2pt</PaddingTop> <TextAlign>Center</TextAlign> </Style> <Value>This is a Report Header</Value> <Width>7.125in</Width> <rd:DefaultName>textbox1</rd:DefaultName> </Textbox> </ReportItems> </PageHeader> <PageHeight>11.69in</PageHeight> <PageWidth>8.27in</PageWidth> <RightMargin>0cm</RightMargin> <TopMargin>2cm</TopMargin> <Width>19.04762cm</Width> <rd:DrawGrid>true</rd:DrawGrid> <rd:ReportID>da9af825-82e3-4be8-9dd3-65cd486c9b44</rd:ReportID> <rd:SnapToGrid>true</rd:SnapToGrid> </Report> END_OF_RDLDatA } }
Comments
Width := 8.5in & Height := 11in
Than check it's working Properly.
Microsoft Dynamics NAV Consultant
Jatin's Blog