Quantcast
Channel: SQL Server Reporting Services, Power View forum
Viewing all articles
Browse latest Browse all 10045

Extra Page Breaks When Exporting RDLC To PDF AKA RDLC BASICS

$
0
0

I have read all the suggested related threads NAD MANY MANY MANY More, to no avail,   before posting this.   I need to get a better understanding on RDLC as we are using the viewer in our web app, and we then export to PDF using ItextSharp. Basically I get an array of bytes from the reportViewer from Report.Render("PDF",,,,,,);  parameters not listed you get the point..

When I design the RDLC in a separate solution I preview it and I do not have PAGE Breaks after EVERY row as I do when I use the report in our REAL web app.    There is NO sub report in this and I have tried everything from using the report wizard and no grouping , to rectangles or list boxes to enclose raw fields,   to the magic formula added in the row grouping definition [=((RowNumber(Nothing) Mod 10) = 0)] as exemplified in many a suggested answer...

Its really plain and Simple data schema so Please Help me ( and I'm sure Many many Others ) understand some basics here.

My forced datatable (DateSet) that I hacked up to provide a source to create my RDLC is comprised of three simple text fields.

A block of UserText  another block of TextInstructions and finally a Customer-esque block of data.

There is seriously nothing to group on here but I do have another field available who's value is common to all these rows should I need to use it for grouping.    Lets Say  

Alpha      UserDataOne   UserTextInstructions1   CustomerDataOne

Alpha      UserDataTwo   UserTextInstructions2   CustomerDataTwo

Normally I wouldn't even consider creating a grouping but the many suggestions I get in my search on "how to prevent unwanted page breaks after EVERY row in RDLC"  is suggesting that this is the answer.   Please understand that when I review my work in the  RDLC development solution there are NO erroneous pages breaks after every row.   I have subtracted the margins I understand the width of the objects must be less than page width sans the sum of the margins.

Its just not coming together, and the fact that it looks fine in the solution I'm developing the RDLC in doesn't help matters.

I'm now at the point where I want to jump back to the wizard and force in the common field to group on and see if that will keep these results grouped together ..

CRTMCSD

<?xml version="1.0" encoding="utf-8"?><Report xmlns="http://schemas.microsoft.com/sqlserver/reporting/2008/01/reportdefinition" xmlns:rd="http://schemas.microsoft.com/SQLServer/reporting/reportdesigner"><Body><ReportItems><Rectangle Name="Rectangle1"><ReportItems><Tablix Name="Tablix3"><TablixCorner><TablixCornerRows><TablixCornerRow><TablixCornerCell><CellContents><Textbox Name="Textbox25"><CanGrow>true</CanGrow><KeepTogether>true</KeepTogether><Paragraphs><Paragraph><TextRuns><TextRun><Value>Resident Data</Value><Style><FontWeight>SemiBold</FontWeight></Style></TextRun></TextRuns><Style /></Paragraph></Paragraphs><rd:DefaultName>Textbox25</rd:DefaultName><Style><Border><Color>LightGrey</Color><Style>Solid</Style></Border><PaddingLeft>2pt</PaddingLeft><PaddingRight>2pt</PaddingRight><PaddingTop>2pt</PaddingTop><PaddingBottom>2pt</PaddingBottom></Style></Textbox></CellContents></TablixCornerCell></TablixCornerRow></TablixCornerRows></TablixCorner><TablixBody><TablixColumns><TablixColumn><Width>4.90552in</Width></TablixColumn><TablixColumn><Width>0.05587in</Width></TablixColumn><TablixColumn><Width>2.42709in</Width></TablixColumn></TablixColumns><TablixRows><TablixRow><Height>0.22917in</Height><TablixCells><TablixCell><CellContents><Textbox Name="Text"><CanGrow>true</CanGrow><KeepTogether>true</KeepTogether><Paragraphs><Paragraph><TextRuns><TextRun><Value>=Fields!Text.Value</Value><Style /></TextRun></TextRuns><Style /></Paragraph></Paragraphs><rd:DefaultName>Text</rd:DefaultName><Style><Border><Color>LightGrey</Color><Style>Solid</Style></Border><PaddingLeft>2pt</PaddingLeft><PaddingRight>2pt</PaddingRight><PaddingTop>2pt</PaddingTop><PaddingBottom>2pt</PaddingBottom></Style></Textbox></CellContents></TablixCell><TablixCell><CellContents><Textbox Name="UserDataString"><CanGrow>true</CanGrow><KeepTogether>true</KeepTogether><Paragraphs><Paragraph><TextRuns><TextRun><Value>=Fields!UserDataString.Value</Value><Style /></TextRun></TextRuns><Style /></Paragraph></Paragraphs><rd:DefaultName>UserDataString</rd:DefaultName><Style><Border><Color>LightGrey</Color><Style>Solid</Style></Border><PaddingLeft>2pt</PaddingLeft><PaddingRight>2pt</PaddingRight><PaddingTop>2pt</PaddingTop><PaddingBottom>2pt</PaddingBottom></Style></Textbox></CellContents></TablixCell><TablixCell><CellContents><Textbox Name="UserDataString1"><CanGrow>true</CanGrow><KeepTogether>true</KeepTogether><Paragraphs><Paragraph><TextRuns><TextRun><Value>=Fields!UserDataString.Value</Value><Style /></TextRun></TextRuns><Style /></Paragraph></Paragraphs><rd:DefaultName>UserDataString1</rd:DefaultName><Style><Border><Color>LightGrey</Color><Style>Solid</Style></Border><PaddingLeft>2pt</PaddingLeft><PaddingRight>2pt</PaddingRight><PaddingTop>2pt</PaddingTop><PaddingBottom>2pt</PaddingBottom></Style></Textbox></CellContents></TablixCell></TablixCells></TablixRow></TablixRows></TablixBody><TablixColumnHierarchy><TablixMembers><TablixMember><Group Name="ColumnGroup"><GroupExpressions><GroupExpression /></GroupExpressions></Group><TablixHeader><Size>0.22916in</Size><CellContents><Textbox Name="Textbox23"><CanGrow>true</CanGrow><KeepTogether>true</KeepTogether><Paragraphs><Paragraph><TextRuns><TextRun><Value>Text Instructions</Value><Style><FontWeight>SemiBold</FontWeight></Style></TextRun></TextRuns><Style /></Paragraph></Paragraphs><rd:DefaultName>Textbox23</rd:DefaultName><Style><Border><Color>LightGrey</Color><Style>Solid</Style></Border><PaddingLeft>2pt</PaddingLeft><PaddingRight>2pt</PaddingRight><PaddingTop>2pt</PaddingTop><PaddingBottom>2pt</PaddingBottom></Style></Textbox></CellContents></TablixHeader><TablixMembers><TablixMember /><TablixMember><Visibility><Hidden>true</Hidden></Visibility></TablixMember></TablixMembers></TablixMember><TablixMember><TablixHeader><Size>0.22916in</Size><CellContents><Textbox Name="Textbox10"><CanGrow>true</CanGrow><KeepTogether>true</KeepTogether><Paragraphs><Paragraph><TextRuns><TextRun><Value>User Data String</Value><Style><FontWeight>SemiBold</FontWeight></Style></TextRun></TextRuns><Style /></Paragraph></Paragraphs><rd:DefaultName>Textbox10</rd:DefaultName><Style><Border><Color>LightGrey</Color><Style>Solid</Style></Border><PaddingLeft>2pt</PaddingLeft><PaddingRight>2pt</PaddingRight><PaddingTop>2pt</PaddingTop><PaddingBottom>2pt</PaddingBottom></Style></Textbox></CellContents></TablixHeader></TablixMember></TablixMembers></TablixColumnHierarchy><TablixRowHierarchy><TablixMembers><TablixMember><Group Name="Group1"><GroupExpressions><GroupExpression>=Fields!ResidentDataString.Value</GroupExpression></GroupExpressions><Parent>=Fields!FacilityIdentifier.Value</Parent></Group><SortExpressions><SortExpression><Value>ForcePage</Value></SortExpression></SortExpressions><TablixMembers><TablixMember><Group Name="ResidentDataString"><GroupExpressions><GroupExpression>=Fields!ResidentDataString.Value</GroupExpression></GroupExpressions></Group><TablixHeader><Size>2.34223in</Size><CellContents><Textbox Name="ResidentDataString"><CanGrow>true</CanGrow><KeepTogether>true</KeepTogether><Paragraphs><Paragraph><TextRuns><TextRun><Value>=Fields!ResidentDataString.Value</Value><Style /></TextRun></TextRuns><Style /></Paragraph></Paragraphs><rd:DefaultName>ResidentDataString</rd:DefaultName><Style><Border><Color>LightGrey</Color><Style>Solid</Style></Border><PaddingLeft>2pt</PaddingLeft><PaddingRight>2pt</PaddingRight><PaddingTop>2pt</PaddingTop><PaddingBottom>2pt</PaddingBottom></Style></Textbox></CellContents></TablixHeader></TablixMember></TablixMembers></TablixMember></TablixMembers></TablixRowHierarchy><DataSetName>dsRestorativeOne</DataSetName><Top>0.06958in</Top><Left>0.08985in</Left><Height>0.45833in</Height><Width>9.73071in</Width><Style><Border><Style>None</Style></Border></Style></Tablix></ReportItems><KeepTogether>true</KeepTogether><Top>0.09375in</Top><Left>0.11333in</Left><Height>1.89583in</Height><Width>9.92181in</Width><Style><Border><Style>None</Style></Border></Style></Rectangle></ReportItems><Height>2.22916in</Height><Style /></Body><Width>10.1789in</Width><Page><PageHeader><Height>0.86333in</Height><PrintOnFirstPage>true</PrintOnFirstPage><PrintOnLastPage>true</PrintOnLastPage><ReportItems><Textbox Name="Textbox1"><CanGrow>true</CanGrow><KeepTogether>true</KeepTogether><Paragraphs><Paragraph><TextRuns><TextRun><Value>DART Chart </Value><Style><FontStyle>Italic</FontStyle><FontSize>14pt</FontSize><FontWeight>SemiBold</FontWeight></Style></TextRun><TextRun><Value>®</Value><Style><FontStyle>Normal</FontStyle><FontSize>9pt</FontSize><FontWeight>Normal</FontWeight><TextDecoration>None</TextDecoration></Style></TextRun></TextRuns><Style><TextAlign>Left</TextAlign></Style></Paragraph></Paragraphs><rd:DefaultName>Textbox1</rd:DefaultName><Top>0.11455in</Top><Left>0.12708in</Left><Height>0.32779in</Height><Width>1.3975in</Width><Style><Border><Style>None</Style></Border><PaddingLeft>2pt</PaddingLeft><PaddingRight>2pt</PaddingRight><PaddingTop>2pt</PaddingTop><PaddingBottom>2pt</PaddingBottom></Style></Textbox><Textbox Name="Textbox4"><CanGrow>true</CanGrow><KeepTogether>true</KeepTogether><Paragraphs><Paragraph><TextRuns><TextRun><Value>Restorative Instructions Report</Value><Style><FontStyle>Italic</FontStyle><FontSize>14pt</FontSize><FontWeight>SemiBold</FontWeight></Style></TextRun></TextRuns><Style /></Paragraph></Paragraphs><rd:DefaultName>Textbox4</rd:DefaultName><Top>0.11662in</Top><Left>1.67499in</Left><Height>0.32779in</Height><Width>3.59958in</Width><ZIndex>1</ZIndex><Style><Border><Style>None</Style></Border><PaddingLeft>2pt</PaddingLeft><PaddingRight>2pt</PaddingRight><PaddingTop>2pt</PaddingTop><PaddingBottom>2pt</PaddingBottom></Style></Textbox><Textbox Name="Textbox7"><CanGrow>true</CanGrow><KeepTogether>true</KeepTogether><Paragraphs><Paragraph><TextRuns><TextRun><Value>=Fields!FacilityName.Value + "( " + Fields!FacilityIdentifier.Value + " )"</Value><Style><FontStyle>Italic</FontStyle><FontSize>14pt</FontSize><FontWeight>SemiBold</FontWeight></Style></TextRun></TextRuns><Style><TextAlign>Right</TextAlign></Style></Paragraph></Paragraphs><rd:DefaultName>Textbox7</rd:DefaultName><Top>0.11662in</Top><Left>7.36223in</Left><Height>0.32779in</Height><Width>2.67291in</Width><ZIndex>2</ZIndex><Style><Border><Style>None</Style></Border><PaddingLeft>2pt</PaddingLeft><PaddingRight>2pt</PaddingRight><PaddingTop>2pt</PaddingTop><PaddingBottom>2pt</PaddingBottom></Style></Textbox><Textbox Name="Textbox6"><CanGrow>true</CanGrow><KeepTogether>true</KeepTogether><Paragraphs><Paragraph><TextRuns><TextRun><Value>=Now()</Value><Style><FontStyle>Italic</FontStyle><FontSize>12pt</FontSize><FontWeight>SemiBold</FontWeight></Style></TextRun></TextRuns><Style><TextAlign>Left</TextAlign></Style></Paragraph></Paragraphs><rd:DefaultName>Textbox1</rd:DefaultName><Top>0.43266in</Top><Left>0.12708in</Left><Height>0.32779in</Height><Width>2.41833in</Width><ZIndex>3</ZIndex><Style><Border><Style>None</Style></Border><PaddingLeft>2pt</PaddingLeft><PaddingRight>2pt</PaddingRight><PaddingTop>2pt</PaddingTop><PaddingBottom>2pt</PaddingBottom></Style></Textbox><Line Name="Line3"><Top>0.82989in</Top><Left>0.16485in</Left><Height>0in</Height><Width>9.93071in</Width><ZIndex>4</ZIndex><Style><Border><Style>Solid</Style><Width>3pt</Width></Border></Style></Line></ReportItems><Style><Border><Style>None</Style></Border></Style></PageHeader><PageFooter><Height>0.66542in</Height><PrintOnFirstPage>true</PrintOnFirstPage><PrintOnLastPage>true</PrintOnLastPage><ReportItems><Textbox Name="Textbox9"><CanGrow>true</CanGrow><KeepTogether>true</KeepTogether><Paragraphs><Paragraph><TextRuns><TextRun><Value>  All rights reserved, permitted use only.</Value><Style><FontSize>8pt</FontSize></Style></TextRun></TextRuns><Style /></Paragraph></Paragraphs><rd:DefaultName>Textbox8</rd:DefaultName><Top>0.13374in</Top><Left>0.08985in</Left><Height>0.48945in</Height><Width>7.72237in</Width><Style><Border><Style>None</Style></Border><PaddingLeft>2pt</PaddingLeft><PaddingRight>2pt</PaddingRight><PaddingTop>2pt</PaddingTop><PaddingBottom>2pt</PaddingBottom></Style></Textbox><Textbox Name="Textbox13"><CanGrow>true</CanGrow><KeepTogether>true</KeepTogether><Paragraphs><Paragraph><TextRuns><TextRun><Value>=Now()</Value><Style><FontSize>8pt</FontSize><Format>g</Format></Style></TextRun></TextRuns><Style><TextAlign>Right</TextAlign></Style></Paragraph></Paragraphs><rd:DefaultName>Textbox10</rd:DefaultName><Top>0.13374in</Top><Left>8.57473in</Left><Height>0.1625in</Height><Width>1.52083in</Width><ZIndex>1</ZIndex><Style><Border><Style>None</Style></Border><VerticalAlign>Top</VerticalAlign><PaddingLeft>2pt</PaddingLeft><PaddingRight>2pt</PaddingRight></Style></Textbox><Line Name="Line2"><Top>0.0393in</Top><Left>0.16485in</Left><Height>0in</Height><Width>9.93071in</Width><ZIndex>2</ZIndex><Style><Border><Style>Solid</Style></Border></Style></Line><Textbox Name="Textbox2"><CanGrow>true</CanGrow><KeepTogether>true</KeepTogether><Paragraphs><Paragraph><TextRuns><TextRun><Value>=Globals!PageNumber &amp; " of  " &amp; Globals!TotalPages</Value><Style><FontSize>8pt</FontSize></Style></TextRun></TextRuns><Style><TextAlign>Right</TextAlign></Style></Paragraph></Paragraphs><rd:DefaultName>Textbox2</rd:DefaultName><Top>0.36568in</Top><Left>8.29347in</Left><Height>0.15625in</Height><Width>1.80209in</Width><ZIndex>3</ZIndex><Visibility><Hidden>true</Hidden></Visibility><Style><Border><Style>None</Style></Border><PaddingLeft>2pt</PaddingLeft><PaddingRight>2pt</PaddingRight></Style></Textbox></ReportItems><Style><Border><Style>None</Style></Border></Style></PageFooter><PageHeight>8.5in</PageHeight><PageWidth>11.25in</PageWidth><InteractiveHeight>7.5in</InteractiveHeight><InteractiveWidth>10in</InteractiveWidth><LeftMargin>0.5in</LeftMargin><RightMargin>0.5in</RightMargin><TopMargin>0.5in</TopMargin><BottomMargin>0.5in</BottomMargin><Style /></Page><AutoRefresh>0</AutoRefresh><DataSources><DataSource Name="dsRestorative"><ConnectionProperties><DataProvider>System.Data.DataSet</DataProvider><ConnectString>/* Local Connection */</ConnectString></ConnectionProperties><rd:DataSourceID>d5ee5e11-19ee-4651-be77-6dc9918ff190</rd:DataSourceID></DataSource></DataSources><DataSets><DataSet Name="dsRestorativeOne"><Query><DataSourceName>dsRestorative</DataSourceName><CommandText>/* Local Query */</CommandText></Query><Fields><Field Name="ResidentDataString"><DataField>ResidentDataString</DataField><rd:TypeName>System.String</rd:TypeName></Field><Field Name="Text"><DataField>Text</DataField><rd:TypeName>System.String</rd:TypeName></Field><Field Name="UserDataString"><DataField>UserDataString</DataField><rd:TypeName>System.String</rd:TypeName></Field><Field Name="FacilityName"><DataField>FacilityName</DataField><rd:TypeName>System.String</rd:TypeName></Field><Field Name="FacilityIdentifier"><DataField>FacilityIdentifier</DataField><rd:TypeName>System.String</rd:TypeName></Field></Fields><rd:DataSetInfo><rd:DataSetName>dsRestorative</rd:DataSetName><rd:SchemaPath>C:\_MY CODE\2013\WindowForms RDLC Restorative\RDLC Restorative\RDLC Restorative\dsRestorative.xsd</rd:SchemaPath><rd:TableName>Restorative_RDLC</rd:TableName><rd:TableAdapterFillMethod>Fill</rd:TableAdapterFillMethod><rd:TableAdapterGetDataMethod>GetData</rd:TableAdapterGetDataMethod><rd:TableAdapterName>Restorative_RDLCTableAdapter</rd:TableAdapterName></rd:DataSetInfo></DataSet></DataSets><rd:ReportUnitType>Inch</rd:ReportUnitType><rd:ReportID>41826812-bd93-4fef-928a-543e302e42d8</rd:ReportID></Report>



Viewing all articles
Browse latest Browse all 10045

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>