Définir zone imprssion vba
benama34
-
Papou93 Messages postés 146 Date d'inscription Statut Membre Dernière intervention -
Papou93 Messages postés 146 Date d'inscription Statut Membre Dernière intervention -
Bonjour,
Bonjour,
petit pb d'impression
grace a cette fonction je défint ma plage de cellule à imprimer
j = 1
Do
Cells(j, 1).Select
j = j + 1
Loop While Cells(j, 1) <> ""
j = j - 1
Range(Cells(1, 1), Cells(j, 3)).Select
'puis je défint la mise en page
ActiveSheet.PageSetup.PrintArea = Range(Cells(1, 1), Cells(j, 3))
biensur ca ne marche pas au niveau de print area. quelqu'un peut il m'aider
thanks
Bonjour,
petit pb d'impression
grace a cette fonction je défint ma plage de cellule à imprimer
j = 1
Do
Cells(j, 1).Select
j = j + 1
Loop While Cells(j, 1) <> ""
j = j - 1
Range(Cells(1, 1), Cells(j, 3)).Select
'puis je défint la mise en page
ActiveSheet.PageSetup.PrintArea = Range(Cells(1, 1), Cells(j, 3))
biensur ca ne marche pas au niveau de print area. quelqu'un peut il m'aider
thanks
A voir également:
- Vba print area
- Print artist - Télécharger - Loisirs créatifs
- Print pratic - Télécharger - Photo & Graphisme
- Directory list & print - Télécharger - Divers Utilitaires
- Print manager - Télécharger - Suite bureautique
- Hp universal print driver - Télécharger - Pilotes & Matériel
1 réponse
Bonjour benama34,
Corriges ton code comme suit :
ou plus simplement :
Ou encore plus simple :
A toi de choisir !
Cordialement.
Corriges ton code comme suit :
j = 1 Do Cells(j, 1).Select j = j + 1 Loop While Cells(j, 1) <> "" j = j - 1 Range(Cells(1, 1), Cells(j, 3)).Select ActiveSheet.PageSetup.PrintArea = Selection.Address
ou plus simplement :
j = 1 Do Cells(j, 1).Select j = j + 1 Loop While Cells(j, 1) <> "" j = j - 1 ActiveSheet.PageSetup.PrintArea = Range(Cells(1, 1), Cells(j, 3)).Address
Ou encore plus simple :
j=Range("A65536").End(xlUp).Row ActiveSheet.PageSetup.PrintArea = Range(Cells(1, 1), Cells(j, 3)).Address
A toi de choisir !
Cordialement.