no save
Assistance
Achat
News

Forum | programmation
récupérer adresse cellule pour sélection
bibi_fricotin, le ven. 12 nov. 2004 à 17:21:24
bonjour,
je voudrais séléctionner une plage de cellules qui contient le même nom, en partant de la cellule A10, la colonne A contenant les noms (ex A10=MARTIN; A11=BIBI;A12=BIBI;A13=DUPONT;etc.), pour les encadrer (donc pouvoir bien identifier chaque nom).
ça bloque après ELSE

Range("A10").Select

While ActiveCell.Value <> ""
Dim nom As String
Dim refnom As Range

If ActiveCell.Value = nom Then
Range(ActiveCell + 1).Select
Else
Range(Cells(refnom.Row, 1), Cells(ActiveCell.Row, 6)).Select

Selection.Borders(xlDiagonalDown).LineStyle = xlNone
Selection.Borders(xlDiagonalUp).LineStyle = xlNone

End If

Wend

Quelqu'un aurait-il une solution ?
Merci.


purrofixe
nov. 04
Suivant
REPONSES
purrofixe
nov. 04
bibi_fricotin
nov. 04
purrofixe
nov. 04
bibi_fricotin
nov. 04
purrofixe
nov. 04
purrofixe
nov. 04
bibi_fricotin
nov. 04
purrofixe
nov. 04
bibi_fricotin
nov. 04
purrofixe
nov. 04
Version Web
Réalisé par RedShift
no save