+ Reply to Thread
Results 1 to 6 of 6

How to make it START and STOP at will...

  1. #1
    Registered User
    Join Date
    09-19-2009
    Location
    LONDON
    MS-Off Ver
    Excel 2003
    Posts
    9

    How to make it START and STOP at will...

    Hi All


    I have a spreadsheet that has
    worksheet_calculate and also worksheet_changes, its a combination of the 2...
    and it's purpose is to make a record of the number every time it changes by populating it into the next row, so I end up having a very long data list

    and what happens is that my spreadsheet has real-time data coming into one cell which makes it constantly changing....

    needless to say, when my spreadsheet is opened, it starts to do it immediately...and it wont stop as long as the number keeps on changing.

    I would like to make 2 buttons - one says START, one says STOP
    and when I click on START, then it will start making record of this number and when I click STOP, then it stops recording the changes of this number.

    Anyone know how to write this code?

    thanks

    Last edited by cartedor; 09-21-2009 at 07:11 PM.

  2. #2
    Forum Moderator Leith Ross's Avatar
    Join Date
    01-15-2005
    Location
    San Francisco, Ca
    MS-Off Ver
    2000, 2003, & 2010
    Posts
    23,258

    Re: How to make it START and STOP at will...

    Hello cartedor,

    Due to the interactive nature of programming, it would benefit you to provide either the complete code or the workbook containing the code. This will also reduce time being wasted answering additional questions about layout and format. The more information you provide, the faster you can get an answer.
    Sincerely,
    Leith Ross

    Remember To Do the Following....

    1. Use code tags. Place [CODE] before the first line of code and [/CODE] after the last line of code.
    2. Thank those who have helped you by clicking the Star below the post.
    3. Please mark your post [SOLVED] if it has been answered satisfactorily.


    Old Scottish Proverb...
    Luathaid gu deanamh maille! (Rushing causes delays!)

  3. #3
    Registered User
    Join Date
    09-19-2009
    Location
    LONDON
    MS-Off Ver
    Excel 2003
    Posts
    9

    Re: How to make it START and STOP at will...

    I need to be careful...as I had been warned that i didnt put code into code things...so i hope this is how it's done on the forum

    I have 2 cells, A1 has a formula NOW()
    and B1 has a number that is constantly changing, every second of it will change, and so this code basically keeps the spreadsheet update or calculate all the time, and every time the data in B1 changes, it will make a record and populate it at the next row, so over time, you can plot how this data change with time..

    But the thing is that this spreadsheet will start recording the data as soon as it is opened, and I would like to just make it a bit userfriendly to have a button which you click to start, and when you have enough data, you click to stop it from keep on going.

    I can make the buttons, using the FORM toolbar, thats not a problem, but I searched online for similar codes that i can use to activate or stop it....i cant figure out how to do it.

    Please advise

    thanks

    Please Login or Register  to view this content.

  4. #4
    Registered User
    Join Date
    09-19-2009
    Location
    LONDON
    MS-Off Ver
    Excel 2003
    Posts
    9

    Re: How to make it START and STOP at will...

    Or better yet, if I can specify the time it starts running and the time it stops
    by entering the time into say cell C1 to start
    and D1 the time to stop running....

    is there anything advance like that?

  5. #5
    Forum Moderator Leith Ross's Avatar
    Join Date
    01-15-2005
    Location
    San Francisco, Ca
    MS-Off Ver
    2000, 2003, & 2010
    Posts
    23,258

    Re: How to make it START and STOP at will...

    Hello cartedor,

    You can remove the Worksheet_Calculate() event code as it is not needed. This macro will check if the time in "B1" falls within the start and stop times in cells "C1" and "D1" respectively.
    Please Login or Register  to view this content.

  6. #6
    Registered User
    Join Date
    09-19-2009
    Location
    LONDON
    MS-Off Ver
    Excel 2003
    Posts
    9

    Re: How to make it START and STOP at will...

    thanks Ross

    it works now!!!

    thanks so much!!!
    this is genius piece of work!!

    thanks so much!!!
    Last edited by cartedor; 09-21-2009 at 07:11 PM.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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