TfrxDateEditControl
Hi,
I have a form with a TfrxDateEditControl on it and would like the date to default to the current date not the date set in the properties value. I have looked through the documentation and sample reports but I seem to be missing something.
If someone could point me in the right direction, it would be much appreciated.
Thanks
I have a form with a TfrxDateEditControl on it and would like the date to default to the current date not the date set in the properties value. I have looked through the documentation and sample reports but I seem to be missing something.
If someone could point me in the right direction, it would be much appreciated.
Thanks
Comments
begin
dateedit1.date:= now;
end;
Thank you....You have saved me from pulling all my hair out. I appreciate your help very much!
Hi Again,
When I have two date fields on a dialog page i.e. start date and end date, when I enter a different date in the start date field and then click on the end date, the start date switches back to 'now'.
Code:
procedure DialogPage1OnActivate(Sender: TfrxComponent);
begin
sDate.date:= now;
end;
begin
eDate.date:= now;
end.
I've tried switching the eDate the the sDate and that fixes the start date but then the end date switches back to 'now' if I click on the start date.
Am I using this in the proper format? As you can tell I'm a noobie so if you can point me in the right direction I would be greatful.
Thanks,
Brian
look where you wrote your code, you put it in the begin end. block of the code page
this block is the first to be processed so edate is set before the activate event anwhen you click
problem.set both dates in the onactivate event.
That worked perfectly, I'm beginning to see the light:)
Thanks GordK.