PC Review


Reply
Thread Tools Rate Thread

date data type

 
 
=?Utf-8?B?TnVtYmVyMjQ=?=
Guest
Posts: n/a
 
      20th Feb 2006
I have a date field in my table, called inductiondate, which is set as short
date. The user will be keying several records in per day, all with the same
date (Not the current day). I want to store the first date they enter and
automatically display it on each add new screen.
I have called the date storedate (dim storedate as date), but when I try to
put storedate into the induction date field on my form, I get the followong
error:-
RunTimeError
-2147352567(800220009) You can't assign a value to this object.
Can anybody help?

TIA
 
Reply With Quote
 
 
 
 
Al Camp
Guest
Posts: n/a
 
      20th Feb 2006
Make the latest entry into InductionDate the Default value.
Use the AfterUpdate event of InductionDate...

Private Sub InductionDate_AfterUpdate()
InductionDate.DefaultValue = "#" & InductionDate & "#"
End Sub

Let's say you enter 2/20/06 in Induction date. When you open a new
record, that date will be entered into InductionDate by default, and will
cointinue to do so until you overwrite InductionDate with a new value.
--
hth
Al Camp
Candia Computer Consulting - Candia NH
http://home.comcast.net/~cccsolutions


"Number24" <(E-Mail Removed)> wrote in message
news:1DC0FC47-CBE3-416B-A07A-(E-Mail Removed)...
>I have a date field in my table, called inductiondate, which is set as
>short
> date. The user will be keying several records in per day, all with the
> same
> date (Not the current day). I want to store the first date they enter and
> automatically display it on each add new screen.
> I have called the date storedate (dim storedate as date), but when I try
> to
> put storedate into the induction date field on my form, I get the
> followong
> error:-
> RunTimeError
> -2147352567(800220009) You can't assign a value to this object.
> Can anybody help?
>
> TIA



 
Reply With Quote
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Problem Importing records with Date/Time data type into an Access 2007 data table Cillacil Microsoft Access External Data 0 3rd Apr 2009 08:50 PM
date type data Faisal Microsoft Access Queries 8 20th Mar 2008 09:25 PM
Between [high date] and [low date] formula using Data Type: Text =?Utf-8?B?a2luZ3MxMDA1MjQ=?= Microsoft Access Queries 2 10th Nov 2005 10:28 PM
Convert a string containing a 32-bit binary date to a date data type Remi Caron Microsoft C# .NET 2 22nd Sep 2004 06:23 PM
data pertaining to dates, but date/time data type doesn't work Kendra Microsoft Access 2 6th Feb 2004 10:04 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 09:15 AM.