473,383 Members | 1,815 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,383 software developers and data experts.

Weird problem with DatePicker

Every time I jumped to a new month, the app kept popping up the message box
for subsequent months until 2050! If I stayed within the same month (current
month), it worked fine.
Please take a look at the following codes. Nothing special about it.
Please help!!

Bill

Private Sub dtPicker1_ValueChanged(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles dPicker1.ValueChanged

If dPicker1.Value >= Today Then

Beep()

MsgBox("Invalid Sales date: " & dPicker1.Value & vbCrLf & _

"Please choose a valid Sales date.")

Exit Sub

Else

Call DoLoadCombo()
End If

End Sub
Nov 20 '05 #1
2 1265
Bill
Do you have more than one DateTimePicker?
I see your code has dtPicker1 and dPicker1?
---
Steve Stein -VB .NET Team
This posting is provided "AS IS" with no warranties, and confers no rights.

--------------------
| From: "Bill Nguyen" <bi*****************@jaco.com>
| Subject: Weird problem with DatePicker
| Date: Mon, 3 May 2004 10:36:40 -0700
| Lines: 33
| X-Priority: 3
| X-MSMail-Priority: Normal
| X-Newsreader: Microsoft Outlook Express 6.00.2800.1409
| X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1409
| Message-ID: <#Y**************@TK2MSFTNGP12.phx.gbl>
| Newsgroups: microsoft.public.dotnet.languages.vb
| NNTP-Posting-Host: 66-162-157-205.gen.twtelecom.net 66.162.157.205
| Path:
cpmsftngxa10.phx.gbl!TK2MSFTFEED01.phx.gbl!TK2MSFT NGP08.phx.gbl!TK2MSFTNGP12
phx.gbl
| Xref: cpmsftngxa10.phx.gbl microsoft.public.dotnet.languages.vb:200228
| X-Tomcat-NG: microsoft.public.dotnet.languages.vb
|
| Every time I jumped to a new month, the app kept popping up the message
box
| for subsequent months until 2050! If I stayed within the same month
(current
| month), it worked fine.
| Please take a look at the following codes. Nothing special about it.
| Please help!!
|
| Bill
|
| Private Sub dtPicker1_ValueChanged(ByVal sender As System.Object, ByVal e
As
| System.EventArgs) Handles dPicker1.ValueChanged
|
| If dPicker1.Value >= Today Then
|
| Beep()
|
| MsgBox("Invalid Sales date: " & dPicker1.Value & vbCrLf & _
|
| "Please choose a valid Sales date.")
|
| Exit Sub
|
| Else
|
| Call DoLoadCombo()
|
|
| End If
|
|
|
| End Sub
|
|
|

Nov 20 '05 #2
Steve;
Yes, but it's not the problem. There must be something else that caused the
looping. I had to set the maxdate value to the same month so that it won't
jump to subsequent months. This worked for me but I still cannot figure out
what wrong with the codes.
Thanks
Bill

""Steven Stein [MSFT]"" <ss****@online.microsoft.com> wrote in message
news:02*************@cpmsftngxa10.phx.gbl...
Bill
Do you have more than one DateTimePicker?
I see your code has dtPicker1 and dPicker1?
---
Steve Stein -VB .NET Team
This posting is provided "AS IS" with no warranties, and confers no rights.
--------------------
| From: "Bill Nguyen" <bi*****************@jaco.com>
| Subject: Weird problem with DatePicker
| Date: Mon, 3 May 2004 10:36:40 -0700
| Lines: 33
| X-Priority: 3
| X-MSMail-Priority: Normal
| X-Newsreader: Microsoft Outlook Express 6.00.2800.1409
| X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1409
| Message-ID: <#Y**************@TK2MSFTNGP12.phx.gbl>
| Newsgroups: microsoft.public.dotnet.languages.vb
| NNTP-Posting-Host: 66-162-157-205.gen.twtelecom.net 66.162.157.205
| Path:
cpmsftngxa10.phx.gbl!TK2MSFTFEED01.phx.gbl!TK2MSFT NGP08.phx.gbl!TK2MSFTNGP12 phx.gbl
| Xref: cpmsftngxa10.phx.gbl microsoft.public.dotnet.languages.vb:200228
| X-Tomcat-NG: microsoft.public.dotnet.languages.vb
|
| Every time I jumped to a new month, the app kept popping up the message
box
| for subsequent months until 2050! If I stayed within the same month
(current
| month), it worked fine.
| Please take a look at the following codes. Nothing special about it.
| Please help!!
|
| Bill
|
| Private Sub dtPicker1_ValueChanged(ByVal sender As System.Object, ByVal e As
| System.EventArgs) Handles dPicker1.ValueChanged
|
| If dPicker1.Value >= Today Then
|
| Beep()
|
| MsgBox("Invalid Sales date: " & dPicker1.Value & vbCrLf & _
|
| "Please choose a valid Sales date.")
|
| Exit Sub
|
| Else
|
| Call DoLoadCombo()
|
|
| End If
|
|
|
| End Sub
|
|
|

Nov 20 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

6
by: Jure Erznoznik | last post by:
I just spent the whole day on solving this problem but still have no success. This is what i do: ModalDialog.window = window.open("", "error", "toolbar=no,width=" + iWidth + ",height=" +...
7
by: Malcolm Webb | last post by:
I use the Microsoft Access Calendar (ActiveX) to pass dates into queries and reports. I have recently come across the Microsoft Access DatePicker developed by Brendan Kidwell and I now use this...
8
by: Alan Silver | last post by:
Hello, I'm trying to write a simple user control as an exercise (and 'cos it might be useful). I am trying to do a simple date picker, which consists of three drop down lists, one for the day,...
2
by: flipdoubt | last post by:
What do most people use for a DatePicker and is a DatePicker included in ASP.NET 2.0? I've seen some of the commercial products out there, but the redistributable license for most of them is too...
3
by: Nathan Sokalski | last post by:
I am working on a simple user control composed of 3 DropDownLists that will be used to select Dates. The purpose of the control is to all the user to choose a date using dropdown lists but not need...
2
by: Pipo | last post by:
Nobody knows how to get the values provided in the client can be read in the user-control? If have made a Web Custom Control with 2 textboxes and 1 dropdownlist. The user fills in my control (the...
0
by: Armand | last post by:
Hi All, is anyone of you have any good resource about implementing datepicker that is binded into asp:textbox control? I do have a client side datepicker in JS, but it is binded to html input...
8
by: shaielinna | last post by:
<? ob_start(); session_start(); require('../includes/inc.php'); require('../includes/settings.php'); include("../includes/dbconnect.php");?> <?php // requires the class require...
6
by: ichibon | last post by:
Hi, I have trouble setting the position of the DatePicker, a control from WPF Toolket June 2009 release. When click on the DatePicker control, the Calendar always open as a drop down and expands...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.