R@chid
XLDnaute Barbatruc
Bonjour,
svp, j'ai ces deux macros qui fonctionnaient très bien avec la version 2010, maintenant que je suis passé à la version 2016, les macros posent problème et fonctionnent pas et étant nul en la matière je ne sais pas vraiment d'où vient le problème.
Macro 1 :
Sub AfficherOngletsEleves(Optional Factice As String)
Dim w As Worksheet, af As Variant
Application.ScreenUpdating = False
ActiveWorkbook.Unprotect Password:="MotDePasse"
For Each w In Worksheets
If w.Name = w.[C7] Then Problème sur cette ligne
If IsEmpty(af) Then af = Not w.Visible
w.Visible = af
End If
Next
ActiveWorkbook.Protect Password:="MotDePasse"
End Sub
Macro 2:
Sub AfficherOnglets(Optional Factice As String)
Dim w As Worksheet, af As Variant
Application.ScreenUpdating = False
ActiveWorkbook.Unprotect Password:="MotDePasse"
For Each w In Worksheets
If w.[B7] Like "*Nom*" And w.[C7] = "" Then
If IsEmpty(af) Then af = Not w.Visible
w.Visible = af
End If
Next
ActiveWorkbook.Protect Password:="MotDePasse"
End Sub
Je remercie d'avance M. Job75 qui m'a beaucoup aidé et qui m'a fait les macros.
et merci à tout le monde de l'attention que vous voudrez porter à ma question
Re : problème résolu tout seul, les macros ont été corrompues apparemment et je ne sais pas pourquoi.
Merci
svp, j'ai ces deux macros qui fonctionnaient très bien avec la version 2010, maintenant que je suis passé à la version 2016, les macros posent problème et fonctionnent pas et étant nul en la matière je ne sais pas vraiment d'où vient le problème.
Macro 1 :
Sub AfficherOngletsEleves(Optional Factice As String)
Dim w As Worksheet, af As Variant
Application.ScreenUpdating = False
ActiveWorkbook.Unprotect Password:="MotDePasse"
For Each w In Worksheets
If w.Name = w.[C7] Then Problème sur cette ligne
If IsEmpty(af) Then af = Not w.Visible
w.Visible = af
End If
Next
ActiveWorkbook.Protect Password:="MotDePasse"
End Sub
Macro 2:
Sub AfficherOnglets(Optional Factice As String)
Dim w As Worksheet, af As Variant
Application.ScreenUpdating = False
ActiveWorkbook.Unprotect Password:="MotDePasse"
For Each w In Worksheets
If w.[B7] Like "*Nom*" And w.[C7] = "" Then
If IsEmpty(af) Then af = Not w.Visible
w.Visible = af
End If
Next
ActiveWorkbook.Protect Password:="MotDePasse"
End Sub
Je remercie d'avance M. Job75 qui m'a beaucoup aidé et qui m'a fait les macros.
et merci à tout le monde de l'attention que vous voudrez porter à ma question
Re : problème résolu tout seul, les macros ont été corrompues apparemment et je ne sais pas pourquoi.
Merci
Dernière édition: