Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

vb.net stored datetime is within 15 seconds from now()

Posted on 2014-02-09
2
Medium Priority
?
396 Views
Last Modified: 2014-02-09
Hi all,


i have stored a datetime dv.Row.Item("Time") and i want to check if that time is withing the last 15 seconds so a can show an image


how could i do this if an if statement?
0
Comment
Question by:runnerjp2005
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 70

Expert Comment

by:Éric Moreau
ID: 39845398
0
 
LVL 45

Accepted Solution

by:
AndyAinscow earned 2000 total points
ID: 39845421
something like this is what you want
        Dim dt As DateTime
dt = dv.Row.Item("Time")
        If dt <= DateTime.Now And dt >= DateTime.Now.AddSeconds(-15) Then
            'show your image
        End If
0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

User art_snob (http://www.experts-exchange.com/M_6114203.html) encountered strange behavior of Android Web browser on his Mobile Web site. It took a while to find the true cause. It happens so, that the Android Web browser (at least up to OS ver. 2.…
Today I had a very interesting conundrum that had to get solved quickly. Needless to say, it wasn't resolved quickly because when we needed it we were very rushed, but as soon as the conference call was over and I took a step back I saw the correct …
In this video, Percona Director of Solution Engineering Jon Tobin discusses the function and features of Percona Server for MongoDB. How Percona can help Percona can help you determine if Percona Server for MongoDB is the right solution for …
Screencast - Getting to Know the Pipeline

597 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