I asked a question some time ago about the maximum string length of the Excel print area:
< /
The print area has been set to 255 for Excel 2010.
I think that this is just a property to read, but (here sticking to the straw), rise the length of the print area? Could the Excel plug-in possibly be? If not, after reaching up to 255, I have to program a new print area. Edit: Category ("A1: C3, A5: B6, C7: D8, E1: E2, G 1: G2, A10: A11, A13: A14, A16: A17, A19: A20, A22: A23, A25: A26, A28: A29, A30: A31, A33: A35, A37: A38, A40: A41 , A43: A44, A46: A47, A49: A50, A52: A53, A55: A56, A58: A59, A61: A63, A65: A66, A68: A69, A71: A72, A74: A75, A77: A78, A80: A81, A83: A84, A86: A87, A88: A8 9, A9 1: A92). Name = "My Nominated Range" Works OK - 253 characters Category ("A1: C3, A5: B6, C7: D8, E1: E2, G1: G2, A10: A11, A13: A14, A16: A17, A19 : A20, A22: A23, A25: A26, A28: A29, A30: A31, A33: A35, A37: A38, A40: A41, A43: A44, A46: A47, A49: A50, A52: A53, A55: A56 , A58: A59, A61: A63, A65: A66, A68: A69, A71: A72, A74: A75, A77: A78, A80: A81, A83: A84, A86: 87, A-88: A8 9, A9 1: A 92, A 94: A 9 5). Name = "mimemade range" run-time error 1004 - (261 characters) So, I think now I should set up several named categories, then print the active sheet Should set the area, using each named category? There is a limit of 255 characters on the named range. The next solution will be to hide the rings that you do not want to print: Cheat with named categories: < / P> Range ("A1: C3, A5: B6, C7: D8"). Name = "Mimemade Range" Then
ActiveSheet.PageSetup.PrintArea = "MyNamedRange"
Private Sub Workbook (Cancel as the first Boolean) If ActiveSheet.Name = " Sheet1 "then cancel = true cancel the default print method so that we can print stuff myself. Application.EnableEvents = False application.ScreenUpdating = False with ActiveSheet .ows (" 12 "). Hide EntireRow.Hidden = True, hide what you hide. Do ("15"). Hide EntireRow.Hidden = True ', hide those you hide. PrintOut .Rows ("12") .EntireRow.Hidden = False' After showing them .Ro ("15"). EntireRow.Hidden = wrong end with the application EnableEvents = True Application.ScreenUpdating = True End if End sub
Comments
Post a Comment