Ms access set date variable to null
New posts. Search forums. Log in. JavaScript is disabled. For a better experience, please enable JavaScript in your browser before proceeding. You are using an out of date browser. It may not display this or other websites correctly. You should upgrade or use an alternative browser. Thread starter hardy Start date Mar 9, Local time Today, Joined Apr 27, Messages Hi, How do you set a date variable as null?!?
Local time Today, Joined Nov 3, Messages 6, You cannot. Only Variants can be Null. Active 11 years, 6 months ago. Viewed 3k times. Simple question: how can init a Date value with a null value in VBA? EDIT: I was just wondering if it's possible. Improve this question. I do not think you can, why do you need to do this?
Okay, you mean only a declaration and no explicit initialization? When you declare something as date, its value is set, similarly if you declare something as boolean, its value is false. It is one of the advantages of declaring variables, only certain values are accepted. It's not the actual data stored there, which instead is Knowing this is important so you can realize that with different date format settings in your Control Regional Settings, the same underlying value in the data field may display as different things.
The underlying stored value is the same, all the differs is the display format. Show 7 more comments. Active Oldest Votes. Chris Patterson Chris Patterson 3 3 silver badges 9 9 bronze badges. I have set the required field status to no. Still does not work. And is it possible to leave the field as blank if there is no value to be inserted? Thanks for your help. I encountered this problem and solved it this way. Gandhi Peter Mali Peter Mali 1.
Sign up or log in Sign up using Google. Sign up using Facebook. Sign up using Email and Password. Post as a guest Name. Email Required, but never shown. The Overflow Blog.
Stack Gives Back Safety in numbers: crowdsourcing data on nefarious IP addresses. Featured on Meta.
0コメント