+ Reply to Thread
Results 1 to 2 of 2

Macro to save a snapshot of data?

  1. #1
    DustinS
    Guest

    Macro to save a snapshot of data?

    I have a range of 30 cells that are linked to an outside source that is
    updating them in 10 second cycles. I also have a cell that counts the
    accumulating cycles.

    I have a line chart that shows me the cell variation in real time.

    I would like to take a sample of the values in those 30 cells once every 10
    thousand cycles and save them to another sheet so that I can chart change
    trends over the long term.

    Doe anyone have an example of how I could do this?

    Regards, Dustin




  2. #2
    Gary's Student
    Guest

    RE: Macro to save a snapshot of data?

    Assuming that you have code that runs at every update, include a call to:

    CycleCheck()

    then enter

    Sub CycleChecker()
    cyclecounter=cyclecounter + 1
    if cyclecounter=10000 then
    cyclecounter=0
    ' insert logic to do transfer
    end if
    end sub

    You will need to Dim cyclecounter as long outside the sub to make it static.

    This is un-checked code
    --
    Gary's Student


    "DustinS" wrote:

    > I have a range of 30 cells that are linked to an outside source that is
    > updating them in 10 second cycles. I also have a cell that counts the
    > accumulating cycles.
    >
    > I have a line chart that shows me the cell variation in real time.
    >
    > I would like to take a sample of the values in those 30 cells once every 10
    > thousand cycles and save them to another sheet so that I can chart change
    > trends over the long term.
    >
    > Doe anyone have an example of how I could do this?
    >
    > Regards, Dustin
    >
    >
    >
    >


+ 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