+ Reply to Thread
Results 1 to 3 of 3

Proper syntax to shorten and speed up code

  1. #1
    Registered User
    Join Date
    08-04-2013
    Location
    Worcester, England
    MS-Off Ver
    Excel 2003
    Posts
    1

    Proper syntax to shorten and speed up code

    Hi guys,

    Mitch here! really hoping to get some help with an extremely simple piece of coding.

    I am fairly new to this as you can probably tell from my poor first attempt at the coding. Its extremely simple, and just requires certain data to show when specific a option is chosen from a choice of option tabs/buttons.

    Due to the length of the code, it is very slow. I have tried all different methods of shortening the code but to no avail!

    Any help on this would be very welcome.

    coding is as follows and is fairly laughable compared to the level I have seen on here!

    Please Login or Register  to view this content.
    This carries on approx. 20 more lines for another 2 option buttons hence the slow update when choosing the options...

    I have tried entering the range as "B60:B70" but the sheet doesn't react and update the data.

    I have also tried 'Dim' but due to my rookie level can't seem to get it to work.

    As I have mentioned, I would love some sort of help!

    Perhaps some day I will be giving advice on here but at the moment, this seems unlikely!



    Thank you in advance...

    Mitch
    Last edited by jeffreybrown; 08-04-2013 at 05:13 PM.

  2. #2
    Forum Guru HaHoBe's Avatar
    Join Date
    02-19-2005
    Location
    Hamburg, Germany
    MS-Off Ver
    work: 2016 on Win10 (notebook), private: 365 on Win11 (desktop), 2019 on Win11 (notebook)
    Posts
    8,198

    Re: Proper syntax to shorten and speed up code

    Hi, Mitch,

    getting it together instead of calling each single cell fully qualified:

    Please Login or Register  to view this content.
    Ciao,
    Holger
    Use Code-Tags for showing your code: [code] Your Code here [/code]
    Please mark your question Solved if there has been offered a solution that works fine for you

  3. #3
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    48,246

    Re: Proper syntax to shorten and speed up code

    Please Login or Register  to view this content.

    Regards, TMS
    Trevor Shuttleworth - Retired Excel/VBA Consultant

    I dream of a better world where chickens can cross the road without having their motives questioned

    'Being unapologetic means never having to say you're sorry' John Cooper Clarke


+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Proper IF syntax when using in VBA
    By scott28 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 06-27-2013, 06:25 AM
  2. [SOLVED] proper syntax
    By lundy in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 12-10-2012, 01:44 PM
  3. Proper syntax to shorten Countif formula
    By small_wonder in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 10-01-2012, 09:23 AM
  4. Shorten and speed up code
    By Kr4ftw3rk in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 03-14-2008, 11:55 AM
  5. Proper SQL Syntax - DAO
    By MSweetG222 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 02-17-2006, 05:35 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1