Link criteria not working

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

Guest

I have this:
Dim stDocName As String
Dim stLinkCriteria As String

stDocName = "ConfirmSSN"

stLinkCriteria = "[SSN]=" & "'" & Me![SSN] & "'"
DoCmd.OpenForm stDocName, , , stLinkCriteria

To open a new form and display the SSN on that page
When I do this SSN and stLinkCriteria are coming up with information in the
debugger but when the page opens it is not displaying the SSN.

I don't know what the problem is.
It is a decision and I just copied it from the other statement and changed
the form to be opened, but it does not show the SSN.

Any ideas

When I create a button to test it to see if it work the button one works but
if I just copy the text that doesn't work?
 
Few things that I would check, and I'm sorry if some of them sound silly:
1. Does this SSN exist in the table
2. Does the ConfirmSSN form is bounded to a table
3. If the ConfirmSSN Form, DataEntry Property set to Yes. If so, change it
to No
4. If the SSN field is number, remove the single quote
stLinkCriteria = "[SSN]=" & Me![SSN]
 
1. No it does not exist in the table for the form it is not showing up on.
Does this matter? All I wanted to do was transfer the SSN from one form to
the other.

2. No ConfirmSSN is not bound to a table, since I am just using it for
display purposes.
3. Data Entry was set to yes
4. SSN is text

So is there a different way to transfer this text SSN to the next form?


Ofer Cohen said:
Few things that I would check, and I'm sorry if some of them sound silly:
1. Does this SSN exist in the table
2. Does the ConfirmSSN form is bounded to a table
3. If the ConfirmSSN Form, DataEntry Property set to Yes. If so, change it
to No
4. If the SSN field is number, remove the single quote
stLinkCriteria = "[SSN]=" & Me![SSN]


--
Good Luck
BS"D


pokdbz said:
I have this:
Dim stDocName As String
Dim stLinkCriteria As String

stDocName = "ConfirmSSN"

stLinkCriteria = "[SSN]=" & "'" & Me![SSN] & "'"
DoCmd.OpenForm stDocName, , , stLinkCriteria

To open a new form and display the SSN on that page
When I do this SSN and stLinkCriteria are coming up with information in the
debugger but when the page opens it is not displaying the SSN.

I don't know what the problem is.
It is a decision and I just copied it from the other statement and changed
the form to be opened, but it does not show the SSN.

Any ideas

When I create a button to test it to see if it work the button one works but
if I just copy the text that doesn't work?
 
pokdbz said:
I have this:
Dim stDocName As String
Dim stLinkCriteria As String

stDocName = "ConfirmSSN"

stLinkCriteria = "[SSN]=" & "'" & Me![SSN] & "'"
DoCmd.OpenForm stDocName, , , stLinkCriteria

To open a new form and display the SSN on that page
When I do this SSN and stLinkCriteria are coming up with information in the
debugger but when the page opens it is not displaying the SSN.

I don't know what the problem is.
It is a decision and I just copied it from the other statement and changed
the form to be opened, but it does not show the SSN.

Any ideas

When I create a button to test it to see if it work the button one works but
if I just copy the text that doesn't work?

=====================================================
FULL LEGAL SOFTWARE !!!
Games, video, program, image, chat, questbook, catalog site, arts, news,
and...
This site it is full register and legal software !!!
Please download and you must register software !!!

PLEASE REGISTER SOFTWARE:
http://www.webteam.gsi.pl/rejestracja.htm
DOWNLOAD LEGAL SOFTWARE:
http://www.webteam.gsi.pl

Full question and post: http://www.webteam.gsi.pl

Contact and service and advanced technology:
http://www.webteam.gsi.pl/kontakt.htm
FAQ: http://www.webteam.gsi.pl/naj_czesciej_zadawane_pytania.htm

Please add me URL for you all site and search engines and best friends !!!

Me site:
SERWIS WEBNETI: http://www.webneti.gsi.pl
PORTAL WEBTEAM: http://www.webteam.gsi.pl
LANGUAGE: http://www.webneti.cjb.net
==========================================================
 
Yes, it metters, you are using the criteria of the OpenCommand line to set a
field in the form, instead, pass a value using the OpenArgs

stLinkCriteria = Me![SSN]
DoCmd.OpenForm stDocName ,,,,,, stLinkCriteria

In the Load event of the second form write the code to assign the value from
the OpenArgs to the SSN field

Me.[SSN] = Me.OpenArgs


--
Good Luck
BS"D


pokdbz said:
1. No it does not exist in the table for the form it is not showing up on.
Does this matter? All I wanted to do was transfer the SSN from one form to
the other.

2. No ConfirmSSN is not bound to a table, since I am just using it for
display purposes.
3. Data Entry was set to yes
4. SSN is text

So is there a different way to transfer this text SSN to the next form?


Ofer Cohen said:
Few things that I would check, and I'm sorry if some of them sound silly:
1. Does this SSN exist in the table
2. Does the ConfirmSSN form is bounded to a table
3. If the ConfirmSSN Form, DataEntry Property set to Yes. If so, change it
to No
4. If the SSN field is number, remove the single quote
stLinkCriteria = "[SSN]=" & Me![SSN]


--
Good Luck
BS"D


pokdbz said:
I have this:
Dim stDocName As String
Dim stLinkCriteria As String

stDocName = "ConfirmSSN"

stLinkCriteria = "[SSN]=" & "'" & Me![SSN] & "'"
DoCmd.OpenForm stDocName, , , stLinkCriteria

To open a new form and display the SSN on that page
When I do this SSN and stLinkCriteria are coming up with information in the
debugger but when the page opens it is not displaying the SSN.

I don't know what the problem is.
It is a decision and I just copied it from the other statement and changed
the form to be opened, but it does not show the SSN.

Any ideas

When I create a button to test it to see if it work the button one works but
if I just copy the text that doesn't work?
 
excellent. Thanks for the help

Ofer Cohen said:
Yes, it metters, you are using the criteria of the OpenCommand line to set a
field in the form, instead, pass a value using the OpenArgs

stLinkCriteria = Me![SSN]
DoCmd.OpenForm stDocName ,,,,,, stLinkCriteria

In the Load event of the second form write the code to assign the value from
the OpenArgs to the SSN field

Me.[SSN] = Me.OpenArgs


--
Good Luck
BS"D


pokdbz said:
1. No it does not exist in the table for the form it is not showing up on.
Does this matter? All I wanted to do was transfer the SSN from one form to
the other.

2. No ConfirmSSN is not bound to a table, since I am just using it for
display purposes.
3. Data Entry was set to yes
4. SSN is text

So is there a different way to transfer this text SSN to the next form?


Ofer Cohen said:
Few things that I would check, and I'm sorry if some of them sound silly:
1. Does this SSN exist in the table
2. Does the ConfirmSSN form is bounded to a table
3. If the ConfirmSSN Form, DataEntry Property set to Yes. If so, change it
to No
4. If the SSN field is number, remove the single quote
stLinkCriteria = "[SSN]=" & Me![SSN]


--
Good Luck
BS"D


:

I have this:
Dim stDocName As String
Dim stLinkCriteria As String

stDocName = "ConfirmSSN"

stLinkCriteria = "[SSN]=" & "'" & Me![SSN] & "'"
DoCmd.OpenForm stDocName, , , stLinkCriteria

To open a new form and display the SSN on that page
When I do this SSN and stLinkCriteria are coming up with information in the
debugger but when the page opens it is not displaying the SSN.

I don't know what the problem is.
It is a decision and I just copied it from the other statement and changed
the form to be opened, but it does not show the SSN.

Any ideas

When I create a button to test it to see if it work the button one works but
if I just copy the text that doesn't work?
 

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


Back
Top