View previous topic :: View next topic |
Author |
Message |
Halftime
Joined: 12 Nov 2006 Posts: 7 Location: Charlotte NC
|
Posted: Wed Nov 15, 2006 12:31 pm Post subject: Printing Only Selected Rows |
|
|
I want to print + print preview only the selected rows - I simplify this by just getting the 1st and last selected rows identifiers, but this feature does not appears to work correctly.
Below is a code sample:
int iSelectedRows = virtualTree1.SelectedRows.Count;
PrintPreviewDialog previewDialog = new PrintPreviewDialog();
VirtualTreePrintDocument pd = new VirtualTreePrintDocument(virtualTree1);
pd.DefaultPageSettings.Landscape = true;
if (iSelectedRows >= 2)
{
int iFirstRow;
int iLastRow;
Row[] oSelectedRows;
oSelectedRows = virtualTree1.SelectedRows.GetRows();
iFirstRow = oSelectedRows[oSelectedRows.GetLowerBound(0)].RowIndex;
iLastRow = oSelectedRows[oSelectedRows.GetUpperBound(0)].RowIndex;
if (iFirstRow < iLastRow)
{
pd.StartRowIndex = iFirstRow;
pd.EndRowIndex = iLastRow;
}
else
{
pd.StartRowIndex = iLastRow;
pd.EndRowIndex = iFirstRow;
}
}
previewDialog.Document = pd;
previewDialog.ShowDialog(this);
}
Any Suggestion ?
_________________ Michael Miller
HalfTime Technologies |
|
Back to top |
|
|
Infralution
Joined: 28 Feb 2005 Posts: 5027
|
Posted: Wed Nov 15, 2006 9:53 pm Post subject: |
|
|
There is indeed a bug here. The VirtualTreePrintDocument StartRowIndex property is working correctly however the EndRowIndex property does not work correctly. Rows after EndRowIndex are still printed if they would fit on the same page.
We will fix this with a release in the next few days. _________________ Infralution Support |
|
Back to top |
|
|
Infralution
Joined: 28 Feb 2005 Posts: 5027
|
Posted: Mon Nov 20, 2006 5:03 am Post subject: |
|
|
Version 2.6.3 (VS2003) and 3.2.0 (VS2005) have now been released and fix this issue. _________________ Infralution Support |
|
Back to top |
|
|
|