Results 1 to 1 of 1

HELPHave read all related threads -- cannot figure out a chain of actions/VBA events

Threaded View

  1. #1
    Registered User
    Join Date
    03-25-2015
    Location
    Brooklyn, NY
    MS-Off Ver
    Office 2010
    Posts
    1

    HELPHave read all related threads -- cannot figure out a chain of actions/VBA events

    Hi -- I know this has been covered, but I cannot get this to work on my PC.
    I am a beginner, so apologies for any rudimentary explanations.


    THE SITUATION
    I have a newsfeed plug-in attached to an Excel Workbook called "GoodEvening". the plug-in auto-updates it with real-time metrics, but only upon the workbook (GoodEvening.xlsm) beign opened/refreshed.
    In GoodEvening.xlsm, I have a macro/vba that says the following -- if GoodEvening is idle for 3 min, it saves and closes it. 2 minutes is approx the amt. of time the workbook need to be updated by the plug-in.

    Const idleTime = 180 'seconds
    Dim Start
    Sub StartTimer()
    Start = Timer
    Do While Timer < Start + idleTime
    DoEvents
    Loop
    Application.DisplayAlerts = False
    ActiveWorkbook.Close True
    Application.DisplayAlerts = True
    End Sub
    MY FIX IDEA
    1. Create a Task Schedule that opens GoodEvening at 6AM (EST)
    2. Enable Content automatically
    3. GoodEvening.xlsm connects through plug-in and updates
    4. After the update, if Cell B2, the column B (column name = Gophers) has ANY VALUE IN IT (pre-arranged formula I've set up in field F1), email me with the following message.
    "Good Morning, Josh. [value in cel A2] now has [value in cel B2] Gophers in it." My email address is [josh@aol.com]
    5. After 3 minutes of idle time, the macro saves and closes the workbook GoodEvening

    *this should all happen whether or not my PC is asleep
    **ideally, I'd love a log of the activity (i.e. whether or not an email has been sent, what time GoodEvening opened/saved/closed), any errors and why


    THE PROBLEMS
    a. Aside from the StartTimer VBA (above), I cannot get my task scheduler to open the workbook 'GoodEvening'. It keeps showing an error.
    b. I cannot find an open_workbook macro that works. Admittedly, I don't understand how to construct one from scratch.
    c. While the current StartTimer macro works, it has locked my ability to edit the macro while workbook 'GoodEvening' is open.
    d. I cannot get an email VBa/macro to work at all

    I'm using Excel 2010, Windows 7.

    Any help or insight would be wildly appreciated. Oh, TOTALLY open to suggestions or improvements, too.
    Last edited by 6StringJazzer; 05-21-2015 at 11:57 AM. Reason: code tags

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Sumif for a Range (Backwards from most Threads I have read)
    By farewinners in forum Excel Formulas & Functions
    Replies: 7
    Last Post: 02-28-2014, 01:52 PM
  2. Replies: 4
    Last Post: 02-03-2014, 08:05 AM
  3. Mark Threads As Read
    By Tony Valko in forum Suggestions for Improvement
    Replies: 9
    Last Post: 06-17-2013, 12:31 AM
  4. [SOLVED] Issue - Threads Say 0 Posts but Threads have Mutliple posts
    By Mordred in forum Suggestions for Improvement
    Replies: 17
    Last Post: 03-30-2012, 05:22 PM
  5. Actions between user actions
    By Indiana Epilepsy and Child Neurology in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 08-16-2006, 12:45 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