MackMan
Registered User.
- Local time
- Today, 18:39
- Joined
- Nov 25, 2014
- Messages
- 174
Hi all. I've been racking my brain for this for the last couple of hours...
A simple function to find the first day of this month when a form opens..i.e
Should work fine, and it does on another form that was written pre anniversary update for Win10
However, on a new form created POST anniversary update, I've put the above code on a form_load event and I get
Run-Time error '438';
Object does support this property or method.
In break mode typing, ?date in the immediate window shows exactly the same run-time error.
?cdbl(date()) in the immediate window and I get argument not optional.
However, if I type in ?date or ?cdbl(date()) in the immediate window while I'm not in break mode, I get todays date, and serial number respectively.
I've checked settings on Win 10 regional (to see if it's been changed during the update) and they're all fine.
I've checked textbox formatting and it's exactly the same as the textbox that works.
I've even created a new form, and re written the code for new controls and I still get the error.
Yet, this code is working perfectly on another form.
Anyone else has this problem, or have I overlooked something totally obvious?
A simple function to find the first day of this month when a form opens..i.e
Code:
me.txtstartdate = dateserial(year(date),Month(date),1)
However, on a new form created POST anniversary update, I've put the above code on a form_load event and I get
Run-Time error '438';
Object does support this property or method.
In break mode typing, ?date in the immediate window shows exactly the same run-time error.
?cdbl(date()) in the immediate window and I get argument not optional.
However, if I type in ?date or ?cdbl(date()) in the immediate window while I'm not in break mode, I get todays date, and serial number respectively.
I've checked settings on Win 10 regional (to see if it's been changed during the update) and they're all fine.
I've checked textbox formatting and it's exactly the same as the textbox that works.
I've even created a new form, and re written the code for new controls and I still get the error.
Yet, this code is working perfectly on another form.
Anyone else has this problem, or have I overlooked something totally obvious?