Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 SQL Server Development (2000)
 Date Time

Author  Topic 

vk18
Posting Yak Master

146 Posts

Posted - 2006-10-06 : 15:25:59
Hi
first of all this is a VB6.0 Application. Sorry for posting here.
coz i don't know where to post.

I am trying to open one of our application. I am getting the error

"A date was specified that doesnot fall with in the Min Date and Max date properties".
Usually what happens is when i try to open this application it opens a calendar there i will
select the date. but now it is giving me this error before selecting the date.
any ideas..? below is the code. please advise.
by the way this code is not written by me.
Thanks,


Private Sub mnuOpen_Click()
Dim nBand As Integer
Dim nCell As Long
Dim vResponse As Variant
If lDataLoaded Then

If xProgUndo.UpperBound(1) >= 0 Then
vResponse = MsgBox("Save changes?", vbYesNoCancel, "Confirm?")

If vResponse = vbYes Then

Load dlgSave
dlgSave.txtScenarioName = lblScenario.Caption & ""
dlgSave.Show 1
frmMain.lblScenario.Caption = ""
ElseIf vResponse = vbCancel Then

Exit Sub
End If
End If

frmMain.lblScenario.Caption = ""
picOuterGridArea(0).Visible = False
picOuterStations(0).Visible = False
picOuterTimeBar.Visible = False
HScroll1.Visible = False
HScroll1.Value = HScroll1.Min
VScroll1(0).Visible = False
VScroll1(0).Value = VScroll1(0).Min


For nCell = 1 To xProg.UpperBound(1)
If xControlLog(nCell, 1) = True Then

Unload lblCell(nCell)
xControlLog(nCell, 1) = False
End If

If xControlLog(nCell, 2) = True Then

Unload imgJip(nCell)
Unload picJip(nCell)
xControlLog(nCell, 2) = False
End If

If xControlLog(nCell, 3) = True Then

Unload imgLip(nCell)
Unload picLip(nCell)
xControlLog(nCell, 3) = False
End If
Next

On Error Resume Next
For nCell = 1 To xStations.UpperBound(1)

Unload lblStatCell(nCell)
Next

For nBand = 1 To xBandInfo.UpperBound(1)
Unload lblDrag(nBand)
Unload lblStatDrag(nBand)
Unload frmMain.picInnerGridArea(nBand)
Unload frmMain.picOuterGridArea(nBand)
Unload frmMain.picInnerStations(nBand)
Unload frmMain.picOuterStations(nBand)
Unload VScroll1(nBand)
Next
On Error GoTo 0
lDataLoaded = False
End If
Load frmOpen
frmOpen.MonthView1.Value = Format(Date, "mm/dd/yy")

frmOpen.Show 1
End Sub

Michael Valentine Jones
Yak DBA Kernel (pronounced Colonel)

7020 Posts

Posted - 2006-10-06 : 15:35:27
This appears to have nothing to do with SQL Server.



CODO ERGO SUM
Go to Top of Page

snSQL
Master Smack Fu Yak Hacker

1837 Posts

Posted - 2006-10-06 : 15:40:04
The code you've show isn't the problem - you need to look at the code in frmOpen.
Go to Top of Page

vk18
Posting Yak Master

146 Posts

Posted - 2006-10-06 : 16:14:52
quote:
Originally posted by snSQL

The code you've show isn't the problem - you need to look at the code in frmOpen.



Hi,
In the Form_load i just have

Idataloaded = false.
Thx
Go to Top of Page

snSQL
Master Smack Fu Yak Hacker

1837 Posts

Posted - 2006-10-06 : 18:05:20
Doesn't matter what's in Form_load, what is MonthView1 and is there property code for its Value property?
Go to Top of Page

vk18
Posting Yak Master

146 Posts

Posted - 2006-10-07 : 16:07:32
quote:
Originally posted by snSQL

Doesn't matter what's in Form_load, what is MonthView1 and is there property code for its Value property?



hi any way thx guys, problem solved... i just need to extend the calendar form property
Go to Top of Page
   

- Advertisement -