WITH or not WITH |
Post Reply |
Author | |
Bernie
Senior Member Joined: 05 July 2007 Location: Taiwan Status: Offline Points: 109 |
Post Options
Thanks(0)
Posted: 11 July 2007 at 9:38pm |
Yes, it's a silly question. I read all the samples that the CodejokeSoftware provided, but there are few "WITH ... END WITH" statements. The following codes are mine. I used "WITH ... END WITH" statement to make the program more efficient. Do you experts agree to avoid using "WITh ... END WITH" ? Dim RB As RibbonBar
With CommandBars1 Set RB = .AddRibbonBar("main") With RB .AddSystemButton .AllowMinimize = False .AllowQuickAccessCustomization = False .AllowQuickAccessDuplicates = False .Closeable = False .Customizable = False .EnableFrameTheme .ShowQuickAccess = False .ShowGripper = False End With End With |
|
gshawn
Senior Member Joined: 04 October 2004 Status: Offline Points: 227 |
Post Options
Thanks(0)
|
Unless your With/End With block is inside a time-critical loop it won't matter one bit, so I don't see a reason to avoid using it. The With/End With block is actually good to use for the sake of clarity.
Cheers!
|
|
Post Reply | |
Tweet
|
Forum Jump | Forum Permissions You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |