MSFN Forum: vbs date Functions - MSFN Forum

Jump to content



Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

vbs date Functions Date over code not work Rate Topic: -----

#1 User is offline   msrplus 

  • Group: Members
  • Posts: 1
  • Joined: 22-December 08

  Posted 17 September 2009 - 03:10 PM

Current system date over the set date not work
when less 10,09,2009 or 20,09,2009 over current system date then msg..... :thumbup

'date = current system date

dim startDate,endDate

startDate = CDate("10/09/" & Cstr(Year(TodayDate)))
eDate = CDate("20/09/" & Cstr(Year(TodayDate)))

if startDate < date or endDate > date then
msgbox "10 day over plz update"
else
msgbox "welcome to start"
end if


Plz any Solution or Solve problem :wacko:
Thanks :hello:


#2 User is offline   gunsmokingman 

  • MSFN Master
  • Group: Super Moderator
  • Posts: 2,019
  • Joined: 02-August 03
  • OS:none specified
  • Country: Country Flag

Posted 17 September 2009 - 11:23 PM

Quote


'date = current system date

dim startDate,endDate

startDate = CDate("10/09/" & Cstr(Year(TodayDate)))
eDate = CDate("20/09/" & Cstr(Year(TodayDate)))

if startDate < date or endDate > date then
msgbox "10 day over plz update"
else
msgbox "welcome to start"
end if


Change This
eDate = CDate("20/09/" & Cstr(Year(TodayDate)))
To This
endDate = CDate("20/09/" & Cstr(Year(TodayDate)))
Then try running your code

Share this topic:


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users



All trademarks mentioned on this page are the property of their respective owners
Copyright © 2001 - 2011 msfn.org
Privacy Policy