On Thu, 25 Sep 2003 13:19:50 -0400, "Rick Bean"
<rgbean (AT) NOSPAMmelange-inc (DOT) com> wrote:
Quote:
Shah,
In my simple form test, I added the calendar control, and a button with the following code in it's Click event method:
Wait window dtoc(ThisForm.OleControl1.Object.Value)
The only thing "unusual", is the required "Object" qualifier, because the control doesn't return the date to the "normal" value property. (VFP really creates a "wrapper" around the control which you have to drill into.)
Rick
"ShahJagat" <shahjagat (AT) aol (DOT) com> wrote
I was reading your posting on the calendar control. How can I trap the date
the user selects and pass it to a variable? |
Rick,
I've been using that neat calendar control in a little reminder program and
have been able to extract the date without using the object qualifier. E.g.
cDay=str(thisform.MonthDisplay.Day,2)
cM=str(thisform.MonthDisplay.Month,2)
cY=str(thisform.MonthDisplay.Year,4)
cDate=cM+'/'+cDay+'/'+cY
I renamed the control from OleControl1 to MonthDisplay. I don't remember
why I did it this way, perhaps because the usual value method didn't work
or because the Month, Day, Year are listed in the Properties of the
control.
Recently I tried to distribute the program to another machine on the
network and ran into a problem. I used the Setup wizard to generated the
distribution disk and when I tried to install them an OLE error code popped
up indicating "Class not registered, object is being ignored."
Any idea of how generate the proper distribution files? The FoxPro version
that I'm using is VFP5.
Al