Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C#
  4. How to Count number of specific day

How to Count number of specific day

Scheduled Pinned Locked Moved C#
tutorialhelpquestion
3 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • R Offline
    R Offline
    rockxuyenmandem
    wrote on last edited by
    #1

    For example now is tuesday 20/6/2006, how can i do to cout the number of tuesday from 1/1/2006 to now. Help me huhuhu:(( I tried so hard and got so far

    L T 2 Replies Last reply
    0
    • R rockxuyenmandem

      For example now is tuesday 20/6/2006, how can i do to cout the number of tuesday from 1/1/2006 to now. Help me huhuhu:(( I tried so hard and got so far

      L Offline
      L Offline
      LongRange Shooter
      wrote on last edited by
      #2

      Hmmmmmm sounds like another homework assignment. You will not get a your homework done by us, however I can give you a direction to head: Think: DateTime.AddDays() and DateTime.DayOfWeek along with a for loop.

      1 Reply Last reply
      0
      • R rockxuyenmandem

        For example now is tuesday 20/6/2006, how can i do to cout the number of tuesday from 1/1/2006 to now. Help me huhuhu:(( I tried so hard and got so far

        T Offline
        T Offline
        Tom Delany
        wrote on last edited by
        #3

        System.DateTime today = System.DateTime.Now; int iDOY = today.DayOfYear(); The above will tell you (in iDOY) what day of the year the current date is (i.e. number between 1 and 366). Tom Delany

        1 Reply Last reply
        0
        Reply
        • Reply as topic
        Log in to reply
        • Oldest to Newest
        • Newest to Oldest
        • Most Votes


        • Login

        • Don't have an account? Register

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • World
        • Users
        • Groups