Question

VB.NET code that will count the time you've been online at a particular website
Is it possible?  :s
 
I don't know where to start..
HELP PLEASE  :blush:
 
i was inspired by the android App - Checky that counts how many times you look at your phone.
And now I want to make a version which can be use in a PC.
Basically, my plan is that I want to record how long a user consumes his/her time on a website like Facebook in a day,
then it will notify/alert the user when it exceeds the given time (set by the user) where he/she can only visit the website..
 

sorry for poor explanation ...

4 answers to this question

Recommended Posts

  • 0

Sure.

 

 

Personally I'd first set a cookie with the time when they first visit and then in set intervals compare it with the current time.

 

Then display it with your preferred method.

 

If you want more than a session total, you will need to note the date too.

 

I think JavaScript would be more suitable for this, than VB.NET.

  • 0

How would you know that the user is actually looking at the page and not merely having it open in some tab, perhaps even having the window minimized? Sounds like something you'd do as a browser extension rather than a standalone application because you'd need to query some browser-specific APIs (if they exist). 

  • 0

At a guess, proxification of traffic to said website. There are a few ways to do that, some more complicated than others. Here's one way that may work:

A) Write a program that listens on port 80. This may conflict with other software such as Apache etc.

B) Append entry to hosts file to redirect requests from a website's primary DNS to the local loopback device: 127.0.0.1 Specificwebsite.com

C) Establish connection to real server on port 80 and forward requests to it, all the while recording activity, and potentially denying further requests if a specific condition is met (such as a time quota).

This topic is now closed to further replies.
  • Posts

    • Mp3tag 3.35 by Razvan Serea Mp3tag is a powerful and yet easy-to-use tool to edit metadata (ID3, Vorbis Comments and APE) of common audio formats. It can rename files based on the tag information, replace characters or words from tags and filenames, import/export tag information, create playlists and more. The program supports online freedb database lookups for selected files, allowing you to automatically gather proper tag information for select files or CDs. Mp3tag supports the following audio formats: Advanced Audio Coding (aac) Free Lossless Audio Codec (flac) Monkeys Audio (ape) Mpeg Layer 3 (mp3) MPEG-4 (mp4 / m4a / m4b / iTunes compatible) Musepack (mpc) Ogg Vorbis (ogg) OptimFROG (ofr) OptimFROG DualStream (ofs) Speex (spx) Toms Audio Kompressor (tak) True Audio (tta) Windows Media Audio (wma) WavPack (wv) Mp3tag 3.35 changelog: This version introduces a new Files options page, enhanced toolbar customization, support for RF64 WAV files, improved Discogs and MusicBrainz tag sources, and many other improvements and fixes. See the Release Notes for more details. Download: Mp3tag 64-bit | 5.7 MB (Freeware) Download: Mp3tag 32-bit | 5.2 MB Link: Mp3tag Homepage | Screenshot Get alerted to all of our Software updates on Twitter at @NeowinSoftware
    • The FIFA World Cup is not US centric.
    • It’s amusing how Microsoft is pushing IT admins as if this was a major, game-changing update. In reality, it’s just an enablement package that bumps the build number, which is disappointing compared to the more substantial 22H2 and 24H2 releases. Technically, 25H2, 26H1, and the upcoming 26H2 are essentially the same, differing only in support schedules. They could have included the Windows K2 improvements here, but chose not to. The era of Windows being in the backburner continues, and this 26H2 release feels like an afterthought. Shame, Nadella, shame.
    • Microsoft, totally not confusing /s 25H2 - Current for non-Arm based Windows 26H1 - Current for Arm based Windows 26H2 - Only for non Arm Windows
    • After I installed those, my older but capable Win 11 laptop (16GB RAM) reported it as 26H2 26300.8697. Then I installed it on my big laptop (128GB RAM! Hehe sorry), it reported it as 25H2 26220.8690. Ugh. Do I have to switch Insiders channels from Release to Beta?
  • Recent Achievements

    • Week One Done
      AMV earned a badge
      Week One Done
    • One Month Later
      AMV earned a badge
      One Month Later
    • Collaborator
      ryansurfer98 went up a rank
      Collaborator
    • One Month Later
      Eurosoft10 earned a badge
      One Month Later
    • Week One Done
      Eurosoft10 earned a badge
      Week One Done
  • Popular Contributors

    1. 1
      +primortal
      523
    2. 2
      +Edouard
      174
    3. 3
      PsYcHoKiLLa
      78
    4. 4
      Steven P.
      72
    5. 5
      Michael Scrip
      71
  • Tell a friend

    Love Neowin? Tell a friend!