Changing the data type using a macro

  • Thread starter Thread starter ChuckW
  • Start date Start date
C

ChuckW

Hello,

I have a customer table in which contains a field called
birthday. The data type though is text rather than
date. I cannot change the data type though to date for
reasons that would take too long to explain. What I did
was to write a query that extracts the data our of the
customer table and then create a make table and call it
Birthdays. Then I manually changed the field from text
to date. Now I want to automate this. I want to create a
button on a form that runs a macro. The macro would run
the query that extracts the data out of my table, creates
a make table and then changes the data type from text to
date? All without any pop-ups like "You are about to
paste XXX rows into a table..."?

Can anyone help?

Thanks,

Chuck
 
First create a make table query that converts the string to date format.
cDate(stringField). called bDays. Then create a button using the wizard and
run a macro that does the following: setwarnings = no, runquery bdays
 
Back
Top