Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > ActiveX COM > Command Bars
  New Posts New Posts RSS Feed - WITH or not WITH
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

WITH or not WITH

 Post Reply Post Reply
Author
Message Reverse Sort Order
gshawn View Drop Down
Senior Member
Senior Member


Joined: 04 October 2004
Status: Offline
Points: 227
Post Options Post Options   Thanks (0) Thanks(0)   Quote gshawn Quote  Post ReplyReply Direct Link To This Post Topic: WITH or not WITH
    Posted: 12 July 2007 at 2:56am
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!
Back to Top
Bernie View Drop Down
Senior Member
Senior Member
Avatar

Joined: 05 July 2007
Location: Taiwan
Status: Offline
Points: 109
Post Options Post Options   Thanks (0) Thanks(0)   Quote Bernie Quote  Post ReplyReply Direct Link To This Post 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
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.04
Copyright ©2001-2021 Web Wiz Ltd.

This page was generated in 0.160 seconds.