By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
435,254 Members | 2,418 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 435,254 IT Pros & Developers. It's quick & easy.

VBA Help

P: 1
I have 2 questions:

Firstly, So far this is the SQL script i have:

Expand|Select|Wrap|Line Numbers
  1. CREATE TABLE Users
  2. ([First Name] text,
  3. [Last Name] text,
  4. [Birthdate] date,
  5. [ID] string,
  6. CONSTRAINT [Index1] PRIMARY KEY ([ID]));
Now this works perfectly fine when run from a query but what i need is is to convert it ino VBA format. I have tried everything but i can just not get it to work.

Secondly, I want to create a sign up form where a user enters their First name, Last name, Birthdate and ID number. However when the user clicks the 'sign up now' button I need the information to be inputed into the script above and a new table created with the same name as the ID.

So to sum it up i am looking for help to create a sign up form where users enter information. This information is then taken and a new table is created.

Any help is appreciated. Thankyou.
Feb 5 '08 #1
Share this Question
Share on Google+
1 Reply


mshmyob
Expert 100+
P: 903
You are going to create a NEW TABLE for every user that signs up???? Why would you create a new table. It seems to me you could end up with thousands of tables depending on the number of users.

Should you not just create one table and each new record holds the data for each new user.

I have 2 questions:

Firstly, So far this is the SQL script i have:

Expand|Select|Wrap|Line Numbers
  1. CREATE TABLE Users
  2. ([First Name] text,
  3. [Last Name] text,
  4. [Birthdate] date,
  5. [ID] string,
  6. CONSTRAINT [Index1] PRIMARY KEY ([ID]));
Now this works perfectly fine when run from a query but what i need is is to convert it ino VBA format. I have tried everything but i can just not get it to work.

Secondly, I want to create a sign up form where a user enters their First name, Last name, Birthdate and ID number. However when the user clicks the 'sign up now' button I need the information to be inputed into the script above and a new table created with the same name as the ID.

So to sum it up i am looking for help to create a sign up form where users enter information. This information is then taken and a new table is created.

Any help is appreciated. Thankyou.
Feb 5 '08 #2

Post your reply

Sign in to post your reply or Sign up for a free account.