Click here to Skip to main content
12,695,624 members (27,755 online)

Comments by Alex Perepletov (Top 2 by date)

Alex Perepletov 11-Aug-11 1:12am View
Is it WinForms DataGridView? In DataGridView one would wire to the CellPainting event. In the event handler, one would get a row from DataSource at index e.RowIndex, and set e.CellStyle.BackColor accordingly.
Alex Perepletov 21-Jul-11 14:41pm View
PrintDocument raises the PrintPage event repeatedly, as long as the previous call to PrintPage handler returns e.HasMorePages == true. Setting e.HasMorePages inside the loop has no effect on the number of calls to the PrintPage. Only the last 'e.HasMorePages = false' counts. You should change your code, - make 'cl' member variable, - at the end of the function, make 'e.HasMorePages = cl <= 5;' - do not dispose of the dsPRTDB.

Advertise | Privacy | Mobile
Web02 | 2.8.170118.1 | Last Updated 1 Jan 1900
Copyright © CodeProject, 1999-2017
All Rights Reserved. Terms of Service
Layout: fixed | fluid