Prompt for entry

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi,

I have a form (form a) with a list of buttons on it. When I click on a
(selection) button I am trying to get the form to go to another form (form b)
so the user can enter their name before continuing to the data entry form
(form c).

The code in form a basically says:

stDocName = "form b"
DoCmd.OpenForm stDocName, , , stLinkCriteria

stDocName = "form c"
DoCmd.OpenForm stDocName, , , stLinkCriteria

If I open form b manually of course I get the prompt and every thing is ok.

The problem I am getting is when I click on the button in form a the code
doesn't pause for the entry in form b and opens form c as well (and leaves
the focus on that form). The user hasn't had the opportunity to enter their
username.

It is Monday morning here and I've had a big weekend.
 
You will need to split up your code.

If all you have in Form B is a text box for the data entry, move the code
below to the "Avter Update" event of the textbox.
stDocName = "form c"
DoCmd.OpenForm stDocName, , , stLinkCriteria

You code in Form A will open Form B. Then when the user enters data in the
textbox in Form B the code there will open Form C.
 
Hi Andrew,

It is simpler than you thought, Use the AfterUpdate event of the textbox or
combo box on form b, or a command button on form b, to open form c.
 
Thanks for you're replies but I've misled you.

I should have also put in my post that I want to repeat this process a
number of times (it gets the user name and I need to get the user name this
way [not systemically] as a numberr of people use the PC).

In otherwords button 1 on form a says 'Create new booking' and button 2 says
'Confirm booking'.

I'm wanting the code to go from form a to form b and then form c or form d
and so on.
 
Thanks for you're replies but I've misled you.

I should have also put in my post that I want to repeat this process a
number of times (it gets the user name and I need to get the user name this
way [not systemically] as a numberr of people use the PC).

In otherwords button 1 on form a says 'Create new booking' and button 2 says
'Confirm booking'.

I'm wanting the code to go from form a to form b and then form c or form d
and so on.

--
Andrew


Arvin Meyer said:
Hi Andrew,

It is simpler than you thought, Use the AfterUpdate event of the textbox or
combo box on form b, or a command button on form b, to open form c.
 
You might try User-Level-Security, which would require each person to login:

Security FAQ
http://support.microsoft.com/download/support/mslfiles/SECFAQ.EXE

Lynn Trapp's summarization:
http://www.ltcomputerdesigns.com/The10Steps.htm

http://support.microsoft.com/default.aspx?scid=KB;en-us;q165009
http://download.microsoft.com/download/access97/faq1/1/win98/en-us/secfaq.exe
http://support.microsoft.com/default.aspx?kbid=325261

http://www.jmwild.com/security02.htm
http://www.jmwild.com/security97.htm
http://www.jmwild.com/SecureNoLogin.htm
http://www.jmwild.com/Unsecure.htm

If that's too involved for you, try some form of limited security:

http://support.microsoft.com/kb/179371/en-us
--
Arvin Meyer, MCP, MVP
http://www.datastrat.com
http://www.mvps.org/access
http://www.accessmvp.com

Andrew said:
Thanks for you're replies but I've misled you.

I should have also put in my post that I want to repeat this process a
number of times (it gets the user name and I need to get the user name
this
way [not systemically] as a numberr of people use the PC).

In otherwords button 1 on form a says 'Create new booking' and button 2
says
'Confirm booking'.

I'm wanting the code to go from form a to form b and then form c or form d
and so on.
 
Hi Arvin,

I've tried to follow the 'limited' option but have had no success. I've
stepped through the code and when it comes to the If rs.NoMatch Then
line it always falls through to the MsgBox "Sorry cannot find
password info. Please Try Again"
line.

I can't see it ever trying to check if the password entered is in the
tblPassword table - any ideas?

Also, how do I bring up the 'debug' window as mentioned at the bottom of the
web page? I can see Immediate and Local but Debug?

Thanks


--
Andrew


Arvin Meyer said:
You might try User-Level-Security, which would require each person to login:

Security FAQ
http://support.microsoft.com/download/support/mslfiles/SECFAQ.EXE

Lynn Trapp's summarization:
http://www.ltcomputerdesigns.com/The10Steps.htm

http://support.microsoft.com/default.aspx?scid=KB;en-us;q165009
http://download.microsoft.com/download/access97/faq1/1/win98/en-us/secfaq.exe
http://support.microsoft.com/default.aspx?kbid=325261

http://www.jmwild.com/security02.htm
http://www.jmwild.com/security97.htm
http://www.jmwild.com/SecureNoLogin.htm
http://www.jmwild.com/Unsecure.htm

If that's too involved for you, try some form of limited security:

http://support.microsoft.com/kb/179371/en-us
--
Arvin Meyer, MCP, MVP
http://www.datastrat.com
http://www.mvps.org/access
http://www.accessmvp.com

Andrew said:
Thanks for you're replies but I've misled you.

I should have also put in my post that I want to repeat this process a
number of times (it gets the user name and I need to get the user name
this
way [not systemically] as a numberr of people use the PC).

In otherwords button 1 on form a says 'Create new booking' and button 2
says
'Confirm booking'.

I'm wanting the code to go from form a to form b and then form c or form d
and so on.

--
Andrew


Arvin Meyer said:
Hi Andrew,

It is simpler than you thought, Use the AfterUpdate event of the textbox
or
combo box on form b, or a command button on form b, to open form c.
--
Arvin Meyer, MCP, MVP
http://www.datastrat.com
http://www.mvps.org/access
http://www.accessmvp.com

Hi,

I have a form (form a) with a list of buttons on it. When I click on a
(selection) button I am trying to get the form to go to another form
(form
b)
so the user can enter their name before continuing to the data entry
form
(form c).

The code in form a basically says:

stDocName = "form b"
DoCmd.OpenForm stDocName, , , stLinkCriteria

stDocName = "form c"
DoCmd.OpenForm stDocName, , , stLinkCriteria

If I open form b manually of course I get the prompt and every thing is
ok.

The problem I am getting is when I click on the button in form a the
code
doesn't pause for the entry in form b and opens form c as well (and
leaves
the focus on that form). The user hasn't had the opportunity to enter
their
username.

It is Monday morning here and I've had a big weekend.
 
Hi Arvin,

SORRY!

I have got around my problem by removing my form b (this is where the user
enters their password) and placing the code in the 'On Open' event.

It's so simple when you look at it with fresh eyes!

Thanks


--
Andrew


Arvin Meyer said:
You might try User-Level-Security, which would require each person to login:

Security FAQ
http://support.microsoft.com/download/support/mslfiles/SECFAQ.EXE

Lynn Trapp's summarization:
http://www.ltcomputerdesigns.com/The10Steps.htm

http://support.microsoft.com/default.aspx?scid=KB;en-us;q165009
http://download.microsoft.com/download/access97/faq1/1/win98/en-us/secfaq.exe
http://support.microsoft.com/default.aspx?kbid=325261

http://www.jmwild.com/security02.htm
http://www.jmwild.com/security97.htm
http://www.jmwild.com/SecureNoLogin.htm
http://www.jmwild.com/Unsecure.htm

If that's too involved for you, try some form of limited security:

http://support.microsoft.com/kb/179371/en-us
--
Arvin Meyer, MCP, MVP
http://www.datastrat.com
http://www.mvps.org/access
http://www.accessmvp.com

Andrew said:
Thanks for you're replies but I've misled you.

I should have also put in my post that I want to repeat this process a
number of times (it gets the user name and I need to get the user name
this
way [not systemically] as a numberr of people use the PC).

In otherwords button 1 on form a says 'Create new booking' and button 2
says
'Confirm booking'.

I'm wanting the code to go from form a to form b and then form c or form d
and so on.

--
Andrew


Arvin Meyer said:
Hi Andrew,

It is simpler than you thought, Use the AfterUpdate event of the textbox
or
combo box on form b, or a command button on form b, to open form c.
--
Arvin Meyer, MCP, MVP
http://www.datastrat.com
http://www.mvps.org/access
http://www.accessmvp.com

Hi,

I have a form (form a) with a list of buttons on it. When I click on a
(selection) button I am trying to get the form to go to another form
(form
b)
so the user can enter their name before continuing to the data entry
form
(form c).

The code in form a basically says:

stDocName = "form b"
DoCmd.OpenForm stDocName, , , stLinkCriteria

stDocName = "form c"
DoCmd.OpenForm stDocName, , , stLinkCriteria

If I open form b manually of course I get the prompt and every thing is
ok.

The problem I am getting is when I click on the button in form a the
code
doesn't pause for the entry in form b and opens form c as well (and
leaves
the focus on that form). The user hasn't had the opportunity to enter
their
username.

It is Monday morning here and I've had a big weekend.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads

Data Entry = No 6
stLinkCriteria 3
can't find form 4
need an acDialog clarification 1
cannot filter continuous form data 2
Opening form to specific record 3
Inserting data in forms 1
Close and Return to Form 2

Back
Top