DATEPICKER

DATEPICKER

Postby Ruth » Mon Feb 26, 2024 10:01 am

Dear friends,


I have a datepicker in my dialog and now I am trying to disable dates in the past from selection.
maybe someone would be kind enough to give me a little hint. I was wondering if there is a way to set minimum and maximum and leaving the dates out of this range disabled also visually...to achieve kind of this look

Image

this is my datepicker right now:

Code: Select all  Expand view  RUN
REDEFINE DTPicker oCal1 VAR dDate1 UPDATE OF oDlg ID 4019 ON CHANGE (f_datumneu(cCombo, dDate1, dDate2, oDlg, oBrw, oBrw2), cSayAusgewaehlt := "Abfragedatum: "+dtoc(dDate1), oSayAusgewaehlt:refresh())
 


thank you very much already and kind regards to all
Ruth
User avatar
Ruth
 
Posts: 170
Joined: Fri Dec 07, 2007 1:26 pm

Re: DATEPICKER

Postby nageswaragunupudi » Mon Feb 26, 2024 11:09 am

Code: Select all  Expand view  RUN
oCal1:SetRange( dFirst, dLast )
Regards

G. N. Rao.
Hyderabad, India
User avatar
nageswaragunupudi
 
Posts: 10655
Joined: Sun Nov 19, 2006 5:22 am
Location: India

Re: DATEPICKER

Postby Ruth » Mon Feb 26, 2024 5:18 pm

Dear Mr. Rao,

thank you very much for your answer. This is working wonderfully.
Through searching the forum etc. I also found dtprang1.prg in samples and it is just what I was looking for. Thank you for making this :-)

and also a polite question: is it allowed to copy what´s in samples and integrate it in someone´s own code and what copyrights etc should I mention in case?

again very kind regards and have a nice evening
Ruth
User avatar
Ruth
 
Posts: 170
Joined: Fri Dec 07, 2007 1:26 pm

Re: DATEPICKER

Postby nageswaragunupudi » Tue Feb 27, 2024 4:44 am

is it allowed to copy what´s in samples and integrate it in someone´s own code and what copyrights etc should I mention in case?


You can freely use the code if it works for you.
No restrictions.
Regards

G. N. Rao.
Hyderabad, India
User avatar
nageswaragunupudi
 
Posts: 10655
Joined: Sun Nov 19, 2006 5:22 am
Location: India

Re: DATEPICKER

Postby Ruth » Tue Feb 27, 2024 7:36 am

This is amazing, dear Mr. Rao. Thank you :-) Kind regards to all Ruth
User avatar
Ruth
 
Posts: 170
Joined: Fri Dec 07, 2007 1:26 pm


Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: Google [Bot] and 28 guests