473,690 Members | 3,026 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Displaying the current record

18 New Member
Hi, I am working on a database. I have created a main form and three linked forms. When I enter an ID in the main form all the related information is also displayed on the linked forms. The problem is, when I enter ID the related information is displayed in the subform but when I close the subform, in the main form the record displayed is the very first record of the table, not the current record. What I want is when I close the subform it should display the same record not the first record. Any suggestion on this will be of great help to me. Thanks.
Aug 6 '07 #1
5 1632
missinglinq
3,532 Recognized Expert Specialist
You have inadvertently posted your question in the Articles section rather than in the Forum section of our site, so I have moved it across to the Forum for you.

Linq ;0)>
Aug 6 '07 #2
NeoPa
32,569 Recognized Expert Moderator MVP
Hi, I am working on a database. I have created a main form and three linked forms. When I enter an ID in the main form all the related information is also displayed on the linked forms. The problem is, when I enter ID the related information is displayed in the subform but when I close the subform, in the main form the record displayed is the very first record of the table, not the current record. What I want is when I close the subform it should display the same record not the first record. Any suggestion on this will be of great help to me. Thanks.
It may help to know what you mean by linked forms and subforms. Subforms can't be closed separately from the main form so I know they're not what you have in mind. I won't be able to help unless you clarify your terms I'm afraid.
Aug 6 '07 #3
130975
18 New Member
I am so sorry missinglinq for my mistake and thanks for redirecting my question to the Forum. Let me make more clear. I have a main form with some basic details and a ToggleLink to open a Child form. Employee is the main form and Email_ID is the child form. I linked the child form's Default Value =[Forms]![Employee]![Emp_Code]. When I search the main Employee form and enter an ID, child form shows up the related information. But the problem is when I close the child form and return to main form, it displays the very first record not the current record. I hope I have drafted my question correctly. Kindly help. Thanks.
Aug 7 '07 #4
FishVal
2,653 Recognized Expert Specialist
I am so sorry missinglinq for my mistake and thanks for redirecting my question to the Forum. Let me make more clear. I have a main form with some basic details and a ToggleLink to open a Child form. Employee is the main form and Email_ID is the child form. I linked the child form's Default Value =[Forms]![Employee]![Emp_Code]. When I search the main Employee form and enter an ID, child form shows up the related information. But the problem is when I close the child form and return to main form, it displays the very first record not the current record. I hope I have drafted my question correctly. Kindly help. Thanks.
Hi.

This happens because you invoke [Forms]![Employee].Requery method. I think in your case there is no reason to do this as no records were added to the main form RecordSource.
If some control on the main form (e.g combo or listbox) has e-mails list as RowSource you need just to call Requery method for this particular control.
Aug 7 '07 #5
NeoPa
32,569 Recognized Expert Moderator MVP
I am so sorry missinglinq for my mistake and thanks for redirecting my question to the Forum. Let me make more clear. I have a main form with some basic details and a ToggleLink to open a Child form. Employee is the main form and Email_ID is the child form. I linked the child form's Default Value =[Forms]![Employee]![Emp_Code]. When I search the main Employee form and enter an ID, child form shows up the related information. But the problem is when I close the child form and return to main form, it displays the very first record not the current record. I hope I have drafted my question correctly. Kindly help. Thanks.
I'm assuming (you still use undefined terms ToggleLink & Child form) that what you're trying to tell us is that you have a form ([Email_ID] - by design unconnected to the main form - [Employee]) which is opened from code within an event procedure of the main form. This may be triggered by something the operator selects on that form.
If all that is a true and accurate understanding of what you're saying, can you let us know what code is run that effects the main form after opening the other ([Email_ID]) form? I think this is what FishVal is referring to - but we don't have access to that important information so we're in the dark to a certain extent.

BTW Don't see this as being critical. I appreciate you're trying to share the right information but that can be very difficult to determine sometimes - hence I'm trying to point you in the right direction :)
Aug 7 '07 #6

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

Similar topics

4
3977
by: Bryan | last post by:
I have a results table that is 5 columns wide. the recordset is returned with 48 items. I have no problem displaying 5 per row until I hit the last row where i get a ADODB.Field error '80020009' Either BOF or EOF is True, or the current record has been deleted. Requested operation requires a current record. My question is how do I close of the table row when I reach the EOF? i.e
5
5252
by: tdmailbox | last post by:
I have a form with a child form. In the child form there is a list of names that can grow quite large. On the parent form I want to display the first name from the child form. I set up a test box that is populated with the code =subfrm_media_review_sec_party.Form!first_name & " " & subfrm_media_review_sec_party.Form!last_name It works except that when I flip through the names it populates the parent form with the name of what ever...
9
2873
by: MLH | last post by:
I have a database (datatrek.mdb) with a table named DATA. The table has a date/time field with default value = Now(). It has 100 records in it entered over a 50-minute period. I would like the query to display 100 records with a new, calculated field showing timelapse between time of record entry of current record and time of entry of previous record. For the first record in the dynaset, I'll settle for a value = 30 seconds. For the...
9
2334
by: Susan Bricker | last post by:
Greetings. I am having trouble populating text data that represents data in my table. Here's the setup: There is a People Table (name, address, phone, ...) peopleID = autonumber key There is a Judge Table (information about judges) judgeID = autonumber key
3
15404
by: Typehigh | last post by:
I am a good programmer, but this one stumps me! I have a form with a continuous subform. The continuous subform contains records of data and may reach a depth of 1000's of entities. I have created a search button on my form and it does its job quite well. It presents the user with an inputbox, prompting for the string to search. Then the code returns with a record number of the record which contains the string. Here's the problem. I...
2
3619
by: Robert | last post by:
I have a label on my form lblCount and the following code in my form for displaying a record count: Private Sub Form_Current() Me.RecordsetClone.Bookmark = Me.Bookmark Me!lblCount.Caption = Me.RecordsetClone.AbsolutePosition + 1 End Sub It works fine until I page to the last record and I get:
1
4778
by: NumberCruncher | last post by:
Hi All, I am struggling with setting up my first system of tables, forms,and reports, and could use your help! I am setting up a database to keep track of the production of a produced item. The item is a panel, with a specific texture. There are standard panels that are then produced in a limited number of specific textures. The number of panels/project varies, so I keep track of the actual number of panels per project with the count:...
2
1623
by: Vinda | last post by:
There was a thread from November 12th, 2005 03:51 PM discussing displaying the current record's record number on a form. Wayne replied to the query that it was possible using the code Me.lblNavigate.Caption = "Record " & _ Me.CurrentRecord & " of " _ Me.Recordset.RecordCount But I am unsure as to where this code should go to display the record number in an unbound text box???
2
8510
by: clickingwires | last post by:
How would I go about displaying the current record value in a label? This is the code I'm using and all I get is "1" in the label Dim rst As New ADODB.Recordset Dim cnn As New ADODB.Connection Set cnn = CurrentProject.Connection rst.Open "Elements", cnn, adOpenStatic, adCmdTable Label21.Caption = rst.AbsolutePosition
0
8531
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 effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
8951
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
8786
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 Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
7623
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6457
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5811
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 then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4550
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2965
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
2225
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

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.