ontime

  1. V

    VBA Macro for ontime start and end time

    I have a VBA Macro which runs in loop as below, want to specify the start and end time for it to run. Could any of your please help me. Sub execute() '' Should run only if current time start time is between 11:00 to 14:00 Do MsgBox "test", vbInformation Loop End Sub
  2. F

    Application ontime running randomly !!

    Hello , I have a vba code which captures the data every 20 second from a dynamically changing cell value and stores in the sheet along with some calcuations using Application.Ontime In the sheet , on checking the difference with the timestamp, show data has been entered at 20 seconds most of...
  3. R

    Save file x minutes after a value is entered

    Hi, I have created a spreadsheet for uses to record production testing results ad this forum has been essential in automating some of the task. But now if find that users are not saving the results. I know I can use the OnTime application to autosave the file but I only want this to kick in...
  4. L

    Macro Wont Run When cell is selected ... Application.OnTime EarliestTime:=DownTime

    Hi all, I have a workbook that we use in work in work with a timer function that shuts down the workbook when the workbook hasn't been used for 15 minutes. However, if my peers select a cell and go into edit mode then no macros run and then they go home so no one can edit it. Is there a...
  5. D

    Ontime Event Going haywire at midnight

    Hello! I have a excel project that starts an ontime event on workbook open. This thing works fantastic! However, when midnight rolls around it crashes. After doing some research I have surmised that the problem is when the date changes, the time is now After the initial time set. I tried to...
  6. J

    Run-Time Error 1004 when Stopping Application.OnTime Procedure

    I wrote a macro that allows a user to time the duration of their call through a UserForm, while they continue to enter data about their call on an excel sheet. Most of the time the macro works perfectly but occasionally (randomly it seems) I get an error when attempting to pause/stop the OnTime...
  7. N

    Application.OnTime Unreliable

    Hey all, So I'm coding a program which I want several macros to run about every hour of the day. With my current implementation it works rather often but on a few occasions I'll come into work and notice that new day has not triggered. This happens about once a week without pattern (fails on...
  8. P

    Combination of Application.OnTime + Locked Session + Userform

    Hi all, I wrote a small application.ontime to win some time in the morning, which launch a macro before me arriving at my workplace At the time set by my application.ontime, my computer is opened and only my session is locked Public Sub StartTimer() h_go =...
  9. P

    Excel Addin to save cell value in database periodically

    I have created an Excel Addin in VBA which reads a cell value and save in SQL database. In Addin, I have created a VBA function SubmitCellValue in a module which can be called as =SUBMITCELLVALUE(A7) in excel and save value from A7 in database. Above part is working fine, Now I want to add a...
  10. D

    Use of Application.OnTime from a function

    I am trying to simulate some logic within a spreadsheet in Excel. All the basic logic gates are obvious but I am having trouble generating a pulse function. My intention was to create a function that would set the value of the cell to 1 and then clear it down to 0 after a delay using the...
  11. L

    Repeat several macros every 24h without having to restart the workbook.

    Hi All, Below is the code I use to trigger few macros in different time intervals. Currently I have to remember to close and open workbook at least once in 24 hours otherwise the macros will not perform very important tasks. I was searching though forums and I was trying to implement things I...
  12. O

    Get to know if in Break-Mode and/or on what line?

    Is there a way to know programmatically that we are in BreakMode and maybe even know on what line? I found out that using apostrophes one can start OnTime with parameters and not having the error "Can't execute code in break mode". Application.OnTime now, "'MySub " & now & "'" This will...
  13. T

    Using Application.OnTime Needs to Run Procedure ONLY ONCE

    Thanks in advance for any help provided. Hello, I am kinda of a newbie who has learned everything I currently know about Excel VBA through Google. I have now reached a state where I don't know how to ask Google what I want. So..... I am trying to run a Logsheet spreadsheet which calls DDE...
  14. C

    Application.OnTime Stopping

    So I created the below schedule within the ThisWorkbook object. The schedule worked effectively (when excel wouldn't get closed due to system restart or some other reason - or execute multiple time due to state <> false). However after 5 days the schedule just stopped firing. I isolated...
  15. C

    Application.OnTime Stopping

    So I created the below schedule and within the ThisWorkbook Object. The schedule worked effectively (when excel wouldnt get closed due to system restart or some other reason). However after 5 days the schedule just stopped firing. Isolated events and times for launch and ensured that this sub...
  16. T

    Running a sub once every minute

    Hi I wrote a specific Sub that does out a calculation, and I want that sub to run once every minute (automatically AKA without having to manually click the routine). how can I do this? I know its something involving Application.Ontime but not sure how to write out the code for this. Any help...
  17. K

    Macro to Save As Backup File or Create a Pop Up to save File

    I am not GREAT at Macros, so I will try and explain what I need the best I can. We have a workbook that has a macro already with a Live Clock that calculates the job times etc. It is on a Server for remote access and used by many people 1 at a time. I look in the file at the data to send...
  18. T

    Anyone know a "Super DoEvents" or a way to force OLEDBConnection to update its refreshing property?

    Hi All, I've discovered recently that DoEvents doesn't yield to all events - for instance, OLEDBConnection objects do not update whilst VBA code is running when their state has been changed during a .Calculate call made from VBA, even if followed by a DoEvents loop. Aside from using scheduled...
  19. B

    Stop running OnTime macro when closed. Please Help!

    Hello! I'm really hoping someone can help me. I have searched and searched and I cannot find a solution that works for me. Our network at work has an issue that when we share an excel file, if anyone on Windows 7 (most of us are on XP) opens the file, it will automatically unshare it. So, we...
  20. N

    OnTime macro stops running when Excel minimized

    Hi. I am using Excel2010. My sheet displays values collected from a database via an AddIn. The values are updated by pressing CTRL+G (AddIn function). I have an OnTime macro running SendKeys "^G" to update the values every minute. When the values exceed a certain limit, a sound is played from a...

Some videos you may like

This Week's Hot Topics

  • Problem with Radio Button's format control
    I am creating an employee evaluation template (a sample is below) Column A is the category Column B, C D, E and F will be ratings (unacceptable...
  • Last Display on userform to a Listbox
    [CODE=vba] lstdisplay.ColumnCount = 15 lstdisplay.RowSource = "A1:O600000" [/CODE] So when i do this it Displays everything on the sheet i am...
  • Rename and move files to a new location
    Dear all, I have an excel file with the following information. The actual file name is at column A but i want to rename it using the following...
  • Help with True/False Formula
    Hello! Am stumped how to fix this formula, in which my result returns 'True', but it should return False. =IF(AG2=True...
  • Clear extra characters from a provided range of cells
    Dear All, I have following code which gives me desired output to remove extra characters from a provided range. But it takes too much time when...
  • Help with Current and highest streaks
    Hi there, I've just joined the forum and this is my first post. I've already spent quite a bit of time searching the net and this forum for a...
Top