Hi
I have form with fields:
datefrom
dateto
customer account
salesorder
item
Customer select first dates. If he dont selected dates, customer lookup will dont active. How me check? Thank you
*This post is locked for comments
Hi,
Ivan have understood your problem very well. So, follow him as he instructed you with his reply
thank you!
If I understood correctly from your description, you want to NOT show the customer lookup unless both dates were specified. Correct?
If yes, you can override the lookup method and not call super():
public void lookup()
{
if (DateFrom.dateValue() && DateTo.dateValue())
{
super();
}
}
Alternatively, you can control the value of the property LookupButton on the CustAccount control on modified() method of DateFrom and DateTo, but I don't like that as much, the LookupButton does not behave very well.
Hi,
You can override the lookup method and put your conditions before the super() call.
Do you mean that if there is no value in datefrom and dateto, there won't be any lookup for customer account? If you merely remove the lookup, users still will be able to type in a value. Would it be better if you disable customer account field?
Stay up to date on forum activity by subscribing. You can also customize your in-app and email Notification settings across all subscriptions.
André Arnaud de Cal... 291,240 Super User 2024 Season 2
Martin Dráb 230,104 Most Valuable Professional
nmaenpaa 101,156