473,434 Members | 1,340 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,434 software developers and data experts.

Double Click on Name Field to show record

50
I am using a search form that list records in my database. On the list that shows the records that have been found I have a field called First. When I double click on this field I would like to open that record in the form it was inputed on. I have been partially succesful doing this by using this code:

DoCmd.OpenForm "frmcustomerinformation", acNormal, , "[First]='" & Me("First") & "'"

I have attempted placing this code in the dblclick event and the singleclick event. It does open the form but does not populate the information on it until I go back to the form that shows the results and click or dbl click on it again. I just want to be able to double click and the record show with all the information there. Is there something im missing in my code or is there another way of doing this?
Aug 28 '07 #1
3 4348
missinglinq
3,532 Expert 2GB
Never place this type of code into the Click event of a textbox, always use the Double Click event Otherwise your users cn't use the mouse to move into the textbox without triggering your code!

"does not populate the information on it until I go back to the form that shows the results and click or dbl click on it again." Click or double click on what? At any rate, try this instead:
Expand|Select|Wrap|Line Numbers
  1. DoCmd.OpenForm "frmcustomerinformation", acNormal, , "[First]='" & Me![First] & "'" 
Linq ;0)>
Aug 28 '07 #2
puppydogbuddy
1,923 Expert 1GB
I am using a search form that list records in my database. On the list that shows the records that have been found I have a field called First. When I double click on this field I would like to open that record in the form it was inputed on. I have been partially succesful doing this by using this code:

DoCmd.OpenForm "frmcustomerinformation", acNormal, , "[First]='" & Me("First") & "'"

I have attempted placing this code in the dblclick event and the singleclick event. It does open the form but does not populate the information on it until I go back to the form that shows the results and click or dbl click on it again. I just want to be able to double click and the record show with all the information there. Is there something im missing in my code or is there another way of doing this?
Try this variation on your code syntax and see if helps:

DoCmd.OpenForm "frmcustomerinformation", acNormal, , "[First]='" & Me!First & "'"
__________________________________________________ ___

If the above syntax does not help, try the filter method as shown below:

Dim strFilter as String

strFilter = "[First] = '" & Me!First & "'"

DoCmd.OpenForm "frmcustomerinformation", acNormal, strFilter
Aug 29 '07 #3
missinglinq
3,532 Expert 2GB
I have merged your duplicate threads of this problem, which were posted a mere 23 minutes apart! Please refrain from this prohibited behavior in the future.

From FAQs


Do Not Double Post Your Questions
Double posting is where you start a thread on a topic and then for some reason start another thread on exactly the same topic in the same forum. Please do not do this because

1. It makes it very hard for people to answer you especially if there are answers happening in all the threads you have started because they have to read 2 or more threads in order to see what has already been said.
2. It swamps the forum with your problem resulting in less attention for the other threads.

If you feel for some reason that you post has been overlooked (for instance it hasn't had any replies) please do not repost the question. Post a message to the thread you started, this will bump it back to the top of the thread list for the forum.


Thank you for your attention in this matter.

Linq ;0)>
Aug 29 '07 #4

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

Similar topics

3
by: N. Graves | last post by:
Hello, I'm having trouble with a feature that I would like to add to my database. I would like to have the ability to double click a record on a Sub form and that action would open that...
2
by: Uninvisible | last post by:
I have put together a db for a law firm to keep track of counterfeit activities. There are four parent tables: tblContact tblTransaction tblAction tblFile I have created a form,...
16
by: jhwagner | last post by:
I need to use double data entry with an MS Access database. I have read many arguments and reasons against this on this group but I have to do this. I have seen various tips on how this can be...
1
by: tshad | last post by:
Is there a way to go into the edit mode by just clicking on a field in the row of the DataGrid you want to edit? I would like to "not" show the Edit button when I show the grid. I would like to...
3
by: Neil Wallace | last post by:
Hi, This is an odd one. I've been struggling to get "double click" to work well for my controls. The same event handler works perfectly for buttons, but not for labels. Can anyone tell me...
20
by: hippomedon | last post by:
Hello everyone, I'm looking for some advice on whether I should break the normalization rule. Normally, I would not consider it, but this seems to be a special case. I have created an...
6
by: Jim Devenish | last post by:
I have an unbound form that displays all the days of the year as a calendar. It has 12 rows of text boxes with either 29,30 or 31 in each row. Text box names are of the form: display_01_01,...
3
by: z.ghulam | last post by:
Hi, I have a PROBLEM form with a TASK table embedded as a subform. Each problem can have many tasks. What I'm trying to do is when I double-click on the task ID, the TASK form opens up on that...
0
by: slinky | last post by:
I'm using VS2003 VB.net/ASP.net and have a Datagrid on an .ASPX page that is successfully displaying the records I was expecting. The next step I want to do is to double-click a line (record) and...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
1
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.