?
Solved

get Query From Button Pressing

Posted on 2013-01-15
16
Medium Priority
?
273 Views
Last Modified: 2013-01-15
Hello,
Trying to do the following
When I tyoe in some string in the textbox, and press search, it should show the filtered query results. It not refreshing when I am pressing the button. Please assist
Thank you
R
finalTestPlease.zip
0
Comment
Question by:Rayne
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 11
  • 4
16 Comments
 

Author Comment

by:Rayne
ID: 38780173
check form1 Thank you
0
 
LVL 61

Expert Comment

by:mbizup
ID: 38780178
It looks like the out put is correct to me - its showing ALL records that contain your search string in the ship name.

If you want to show DISTINCT results, change your query's SQL view to:

SELECT DISTINCT tblSource.[Ship Name]
FROM tblSource
WHERE (((tblSource.[Ship Name]) Like "*" & [Forms]![Form1]![myShipName] & "*"));

Open in new window


If that doesnt help, please let us know what is wrong with the output and what your expected results are.
0
 

Author Comment

by:Rayne
ID: 38780218
Hello,

Double click on Form1
Entered “Jones”
Clicked “Search” button
Results shows Everything!! All 66 records

I am not sure if that’s filtering correctly by “Jones”


If I enter in Jones, it should pull all the rows that has jones in that field
0
Three Reasons Why Backup is Strategic

Backup is strategic to your business because your data is strategic to your business. Without backup, your business will fail. This white paper explains why it is vital for you to design and immediately execute a backup strategy to protect 100 percent of your data.

 
LVL 120

Expert Comment

by:Rey Obrero (Capricorn1)
ID: 38780233
ttest this


open the form Form1 and type a value in the textbox, then click on the button
finalTestPlease.accdb
0
 

Author Comment

by:Rayne
ID: 38780238
you need to zip it and attach...i am getting all wierd values in the browser when I open it
0
 

Author Comment

by:Rayne
ID: 38780243
no need to zip, got it
0
 
LVL 120

Expert Comment

by:Rey Obrero (Capricorn1)
ID: 38780250
better use this one
finalTestPleaseRev.accdb
0
 

Author Comment

by:Rayne
ID: 38780258
This works Great, Can you explain me the steps, Capricorn. I am touching access after 5 years. Thank you
0
 
LVL 120

Expert Comment

by:Rey Obrero (Capricorn1)
ID: 38780261
see the codes in the click event of the button.

what steps you want to know?
0
 

Author Comment

by:Rayne
ID: 38780288
How did you set up the  subFrom “frmSource” – the steps
Thank you
0
 

Author Comment

by:Rayne
ID: 38780292
how does the sbuform looks up values from the main form ? like setting the data
0
 

Author Comment

by:Rayne
ID: 38780294
filtered data
0
 

Author Comment

by:Rayne
ID: 38780305
I see this for it but not sure what means
showIt.png
0
 
LVL 120

Accepted Solution

by:
Rey Obrero (Capricorn1) earned 2000 total points
ID: 38780330
<How did you set up the  subFrom “frmSource” – the steps >

select the table then Create Form > datasheet
save the form

the filtering is done by the codes in the click event of the button
0
 

Author Comment

by:Rayne
ID: 38780340
Perfection to the Ultimate

Thanks Capricorn :)
0

Featured Post

Will your db performance match your db growth?

In Percona’s white paper “Performance at Scale: Keeping Your Database on Its Toes,” we take a high-level approach to what you need to think about when planning for database scalability.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article describes a method of delivering Word templates for use in merging Access data to Word documents, that requires no computer knowledge on the part of the recipient -- the templates are saved in table fields, and are extracted and install…
An alternative to the "For XML" way of pivoting and concatenating result sets into strings, and an easy introduction to "common table expressions" (CTEs). Being someone who is always looking for alternatives to "work your data", I came across this …
In Microsoft Access, learn how to “cascade” or have the displayed data of one combo control depend upon what’s entered in another. Base the dependent combo on a query for its row source: Add a reference to the first combo on the form as criteria i…
Access reports are powerful and flexible. Learn how to create a query and then a grouped report using the wizard. Modify the report design after the wizard is done to make it look better. There will be another video to explain how to put the final p…

719 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question