+ Reply to Thread
Results 1 to 8 of 8

Force Update if within specific timeframe?

  1. #1
    Registered User
    Join Date
    04-20-2011
    Location
    Mobile,al
    MS-Off Ver
    Excel 2003
    Posts
    29

    Force Update if within specific timeframe?

    I have a spreadsheet that contains links which must be updated before being e-mailed to recipients.This spreadsheet is completed betwen midnight and 5 am each morning.The problem is that frequently the user chooses not to update ,therefore incomplete data is sent out to e-mail recipients.I'd like to automatically have it update if between 12:01 am and 5am. Any ideas?
    Thanks in advance.
    Last edited by cure4glass1; 07-06-2011 at 05:29 AM.

  2. #2
    Forum Expert
    Join Date
    11-29-2010
    Location
    Ukraine
    MS-Off Ver
    Excel 2019
    Posts
    4,168

    Re: Force Update if within specific timeframe?

    hi, cure4glass1, as far as I understand the not-to-update option is chosen when whorkbook is opened up. If that is the case, place the following code into your file in workbook module. This would make the update regardless of user decision. You can actually turn the link update off, the code will force all links to update on workbook open.

    Please Login or Register  to view this content.

  3. #3
    Registered User
    Join Date
    04-20-2011
    Location
    Mobile,al
    MS-Off Ver
    Excel 2003
    Posts
    29

    Re: Force Update if within specific timeframe?

    Watersev,
    Thanks for the post,One reason the users elect not to update is because it sometimes seems very slow to update.This file only needs to be updated once a day, and that is when the file is complete for the day and this is usually complete between midnight and 5am. That's why I was hoping to force an update only between a specific time frame.
    Thanks again!

  4. #4
    Forum Contributor Dave H9's Avatar
    Join Date
    03-10-2011
    Location
    Manchester, England
    MS-Off Ver
    Excel 2007
    Posts
    418

    Re: Force Update if within specific timeframe?

    Hi cure4glass,

    try adding the below to your code -

    Please Login or Register  to view this content.
    Hope that helps

    Dave H

  5. #5
    Registered User
    Join Date
    04-20-2011
    Location
    Mobile,al
    MS-Off Ver
    Excel 2003
    Posts
    29

    Re: Force Update if within specific timeframe?

    Dave, Thanks for your patience.Believe it or not I am picking up nuggets along the way.
    I added the code, then inserted mine( which I never got to work properly buy itself), but looks as If I have to many End Withs,ifs, or elses...Hope I'm getting closer to making this auto update within a given hour, but so far I'm getting
    Compile Error:Expected End Sub

    Here's my code after adding your suggestion:.

    HTML Code: 
    Last edited by cure4glass1; 07-09-2011 at 05:23 PM.

  6. #6
    Forum Contributor Dave H9's Avatar
    Join Date
    03-10-2011
    Location
    Manchester, England
    MS-Off Ver
    Excel 2007
    Posts
    418

    Re: Force Update if within specific timeframe?

    your really mixing it up here. can you post an example sheet? You have started in the correct way but then you are trying to call a workbook function which just wont work

    Please Login or Register  to view this content.
    An example sheet will help me understand what you are trying to do, just take out any private info.

    Dave H

  7. #7
    Registered User
    Join Date
    04-20-2011
    Location
    Mobile,al
    MS-Off Ver
    Excel 2003
    Posts
    29

    Re: Force Update if within specific timeframe?

    Dave, I agree, it was mixed up, and after so many gyrations with the suggestions offered I don't know exactly where I was at when you offered your addition to my code.At any rate, perhaps I'd be better suited to restate what I need if you don't mind

    I have a spreadsheet(attached) where the links only needs to be updated once each day, between the hours of midnight and 5 am.The issue I'm having is that when users are prompted whether or not to update, they choose not to because it is slow to update( it looks at 31 different files when updating).As I said, it is only necessary to udate once after midnight after all data is entered for the previous day.

    btw, I removed the code from the attached sheet.
    Attached Files Attached Files
    Last edited by cure4glass1; 07-09-2011 at 05:33 PM. Reason: text editing

  8. #8
    Forum Contributor Dave H9's Avatar
    Join Date
    03-10-2011
    Location
    Manchester, England
    MS-Off Ver
    Excel 2007
    Posts
    418

    Re: Force Update if within specific timeframe?

    wow thats quite a project!

    try adding this to the workbook module -

    Please Login or Register  to view this content.
    just change the "'your update code here" to "call" your code.

    crossing my fingers for you

    Dave H

+ 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