Solved

Countdown timer in vb login script

Posted on 2006-06-14
2
293 Views
Last Modified: 2012-08-13
How do I create a countdown timer to a date in a vb login script?  For example, I want a box to pop up at login to say "Only 21 days left until Big Day!"
0
Comment
Question by:Kevin Smith
2 Comments
 
LVL 13

Accepted Solution

by:
rettiseert earned 250 total points
ID: 16906804
Something like this?

    Dim BigDay
    Dim DaysRemaining
   
    BigDay = DateSerial(2006, 6, 30) 'Year, month, day of bigday
    DaysRemaining = DateDiff("d", Date, BigDay)
   
    MsgBox "Only " + Format(DaysRemaining) + " for the big day!", vbInformation
0
 

Author Comment

by:Kevin Smith
ID: 16906969
Worked great, thanks!  I did have to change the last line to:

MsgBox ("Only " &(DaysRemaining) & " for the big day!"), vbInformation

'cause I got a format error.

Thanks rettiseert!
Kevin
0

Featured Post

Highfive + Dolby Voice = No More Audio Complaints!

Poor audio quality is one of the top reasons people don’t use video conferencing. Get the crispest, clearest audio powered by Dolby Voice in every meeting. Highfive and Dolby Voice deliver the best video conferencing and audio experience for every meeting and every room.

Join & Write a Comment

Suggested Solutions

When designing a form there are several BorderStyles to choose from, all of which can be classified as either 'Fixed' or 'Sizable' and I'd guess that 'Fixed Single' or one of the other fixed types is the most popular choice. I assume it's the most p…
Since upgrading to Office 2013 or higher installing the Smart Indenter addin will fail. This article will explain how to install it so it will work regardless of the Office version installed.
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…

706 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

17 Experts available now in Live!

Get 1:1 Help Now