Open Subform At New Entry

Aug 29, 2006

I have a form with a combobox to select a clients name and that pulls up that client in a subform and shows various records for the client. But it always opens up showing the first record and I want it to open up showing a blank record for keying in more data i.e. after the last record.

Can you help at all on this?

many thanks

View Replies


ADVERTISEMENT

Subform Blues - Data Entry Setting Itself To 'No' & Requerying 1 Subform From Another

Dec 5, 2006

2 Subform problems

I have a data entry subform that is only supposed to show an empty record ready to be populated, and a display records subform that is supposed to show all the records. The subforms are both on the same tab of a tab control on my main form.

Problem 1:
The data entry subform shows all the records rather than a blank record. Something on my main form is causing it to show the records when it should not. Any ideas? The Data Entry is set to Yes.

To try to isolate the problem, I created a new form and added the subform to it where it behaves properly:confused:

I then added Me.DataEntry = True to the form open to see if that would solve my problem but it still sets the data entry to no.

If I have the properties box open when in form view of my main form, I can set the data entry to Yes and it works fine until I move to the next record of the main form when it resets to no. Teraing my hair out here.:mad:

My final attempt was to search the entire project to see if there is a "DataEntry = False" somewhere but there isn't. What is setting this property? Any ideas where I should look?


Problem 2:

After entering data in the first subform (data entry form), I want to re-query the second subform but I just can't get the syntax right. I have wrestled with the "Syntax for subs" document downloaded from http://www.mvps.org/access/forms/frm0031.htm (Microsoft MVP site) but to no avail.

My main form is called fdlgPrjDetails, the data entry is via fsubPrjCommentsUsersDataEntry and the subform I wish to requery is fsubPrjCommentsUsers.

None of the attempts below worked giving a cannot find control error.


Private Sub Form_AfterUpdate()
On Error GoTo ErrHandler

Me.Requery

'Me!fsubPrjCommentsUsers.Requery
'Me!fsubPrjCommentsUsers.Form.RecordSource.Requery
'DoCmd.Requery ([fsubPrjCommentsUsers])
'DoCmd.Requery [fsubPrjCommentsUsers]

ExitHere:
Exit Sub

ErrHandler:
MsgBox Err.Number & " - " & Err.Description & Chr(13) _
& Chr(13) & "Error in fsubPrjCommentsUsersDataEntry: Err 003"
Resume ExitHere
End Sub


Any Ideas?

Both problems have me stumped so I'll be grateful to anybody with a scoobie on this.:)

View 10 Replies View Related

What Have I Done? You Can't Open A Subform When It Is Also Open In Design View

Jun 1, 2006

Problem:
Visual Basic run-time error 7792: You can't open a subform when it is also open in Design view.

I have a subform with properties for SourceObject, LinkMasterFields, LinkChildFields changing according to objects and events in the master form.

The subform was bound to a query before which meant that the subform load event was happening as soon as the master form is loaded. I needed to restrict the subform loading until a certain point so I removed the SourceObject property for the masterform's subform. The subform on the master form is now Unbound.

(This is because I'm now running some code on the FormLoad event for the subform which needs to be restricted until the LinkMasterFields and LinkChild Fields properties have been assigned correctly otherwise it takes ages to load.)

Now I'm getting the above error. Obviously, i do not have the subform open anywhere in design view. No Visual Basic windows are open. I've closed the db, closed access, reopened it and clicked on nothing except the masterform. The error occurs when I raise the event in the master form which assigns the sourceobject property to the subform, i.e.

Me.sfmQryAllOV.SourceObject = "sfmQryAllOV"

Can anyone help me? I've googled this but finding no answers.

View 1 Replies View Related

Forms :: How To Make Form To Always Open To New Entry Only

Jul 15, 2013

Is there any setting that I can use that will make a form always open to a new entry?

I don't want people to be able to edit the form.

On the form I have created a New form button and a Save and clear button, but i would prefer it to be that when they open the form its always a new entry and when they hit save it just save and clears and comes back to a new entry form.

These are my buttons.

Code:
Private Sub Command103_Click()
DoCmd.RunCommand acCmdRecordsGoToNew
End Sub

Private Sub Command90_Click()
RunCommand acCmdSaveRecord
Me.Requery
End Sub

View 3 Replies View Related

Open Tab Control For Data Entry When No Records In Table For User?

Nov 29, 2014

I am trying to open TabCtl86 forms in AddData mode if there are no records in a table for a user chosen form cboClientSearch. The tab control has three pages on it. At the moment I am getting an error saying "the form named '0' is either misspelled or doesn't exist".

I am using this at the moment; DoCmd.OpenForm Controls!TabCtl86, acFormDS, , , acFormAdd, acDialog

View 1 Replies View Related

Open Subform At Certain Recordset Based On Subform

Feb 5, 2005

I have a main form which has a subform control in it. when the main form is opened the sub form control contains a list of events in a sub form (a summary view), for the person selected in the main form.

I want to change the subform to a different one which shows the whole event when i click in a field on the subform, based on the event i clicked in. ( i can do it by opening a new form but not with a new subform)

I can make the form change using the following code:

Private Sub Notes_DblClick(Cancel As Integer)

Me.Parent.subformhere.SourceObject = "eventsfullrecord"

End Sub

What code do i need to make it open to the record i clicked in the summary form, rather than just opening to the first record every time?

Not very good at passing recordsets

Thank you

View 4 Replies View Related

Subform Data Entry

Apr 27, 2006

Hello all,

I'm looking for a little help on something that I'm sure is an easy problem. I'm building a form for patients (data from Table: Patients) that contains a subform containing lab values (Table: Lab Values). I'm new at using subforms so I'm in a little over my head.

Both Tables contain the patients name to link them together. When I create the subform, I don't want it to display the patient name, because it is already displayed in the header. But if I don't include that field, I can't link the two tables together. I'm using one of Microsoft's templates off their website (called Contact Manager Database) as a guide, and it has exactly what I want - a sub form that only displays the relevant data for each patient, but when you add a record the data in the table automatically includes the name of the person.

I just can't seem to figure out how to do this. I'm sure I've been very unclear describing this, and I'm sure this is an easy task, but if someone can give me a little direction I would greatly appreciate it.

Cavy

View 3 Replies View Related

Forms :: Open Form From (Edit List Items) Option In Data Entry Mode

Feb 4, 2014

I have several comboboxes in my database from which users select values. However, in most cases, I do want to give them the option to add an item that does not appear while simultaneously updating the underlying table which stores those dropdown values. I have made use of the builtin "allow edit list items" feature of Access 2007 but the form always opens on the first record of the form on which they are to add the new item. Is there a way to specify that it should open in Data Entry view apart from using VBA?

View 4 Replies View Related

Creating Dynamic Hyperlinks - Open Data Entry Form And Navigate To Specific Record

Nov 28, 2011

I have a form that lists records in a table. I would like to have a hyperlink beside each record that will open the data entry form and navigate to that specific record. Right now, the use can only open the form for all records and has to use the record navigation buttons to find the desired record.

View 1 Replies View Related

RFT Problem And Subform Data Entry

Mar 2, 2005

1st:

I have used the Lesban Rich Textbox Control. However, I face a problem with the control and cannot solve. The thing is that whenever I select an item from a combo box which loads a no record it refers to, it always ignore my first letter input. The second one will go just fine (e.g. when I enter ABC...., the control will ignore the A letter) Hope you get what i mean. I dunno if I made mistakes somewhere with the control. Does anyone have any idea that such thing should be done?

2nd:

In the same form as above one, I also designed 2 other subforms, however, it always raises error when I enter data while the main form contains nothing. I want to disable those 2 subforms when the main form record isn't filled out. I found a similar result in the forum, but it doesnot work with Rich Textbox Control's update event.

View 6 Replies View Related

Preventing Multiple Entry In Subform

May 4, 2005

Hi
I have a form and sub form, the sub form is populated from a query and has a column of checkboxes. Basically these checkboxes get checked as part of the form, but only a maximum of five are allowed to be checked. Is there a way of achieving this?
Cheers
Dan

View 1 Replies View Related

How To Require Entry In A Field On A Subform?

Aug 8, 2005

I haven't been able to figure out the code to require entry (for a new record) in a field on a subform - anyone can help with this?

The situation is a contacts database, and each new contact should have a (or multiple) Person Roles entered as well, which is their relationship to the organization.

View 2 Replies View Related

Subform Data Disappearing On Entry

Oct 2, 2006

Hi all,

I apologize if I'm missing something terribly simple.

Here's the background: I have a set of 3 tables linked to a main table based on a field called SampleID. I then have one main form (SAMPLE) with the other 3 tables (INDIVIDUAL, LOCATION & ORGANISM) all as subforms within the main form.

everything seems to work well in terms of links and getting the data into the appropriate tables and retaining the SampleID link. However, during data entry using the tab key, I am unable to find an eloquent way to move from the main form to subform1, then from subform1 to subform2, from subform2 back to main etc. I have set the tab order, and used the afterupdate control to change the focus which works, however as soon as I move from subform1 to subform2, the data just entered disappears from subform1. The data makes it to the table without any problem, but just blanks out the form.

From what I can see, when the subform loses focus it automatically saves the edited record and inserts a new record, thereby blanking out the fields that were just entered. Is there a property that can be set so that a new record is not automatically entered when leaving a subform? Is there a method to do this through coding?

any help would be greatly appreciated!!

Thanks in advance.....

View 3 Replies View Related

Forms :: Subform Relationship With New Entry

Mar 28, 2014

I have a Workorder Form that holds all the fields that apply to the entire project (payment, customer, etc).

Then I have a subform for Stock. This allows there to be several different stock items (and production information relevant to that stock) assigned to a Workorder.

I have successfully linked the two so that when a Workorder is opened, it shows any related Stock in the subform that has already been created.

The problem is new stock entries. I need it to only allow Stock additions to the current open related Workorder.

I currently have it where you can type in the WorkorderID (autonumber) on the Stock subform new entry and it will work. But I do not trust employees to type in the correct number every time they need to add stock to a Workorder. I can't release it this way.

I mean, the whole point is for the database to promote as little error as possible, right?

View 5 Replies View Related

Using Subform Entry As Criteria In A Query

Nov 14, 2012

I have the following Form and Subform. Form name is "100-Select Form". Subform name is "103-Report Dates". Within the subform I have two fields I'm using, "Start Date" and "End Date'.

In my query I have a date field. I want the query to read from the Subform (if I open the subform directly my criteria listed below works, but when the main form is open, my query doesn't seem to be able to read from the subform).

Here is the criteria I have in the date field of my query: >=[Forms]![103-Report Dates]![Start Date] And <=[Forms]![103-Report Dates]![End Date]

I have a feeling that I somehow should be pointing my criteria first to '100-Select Form', and then to '103-Report Dates' within that form, but I'm just not sure how to write this and nothing I'm trying is working.

View 2 Replies View Related

Required Fields And Subform Entry Order

Jun 23, 2005

Hi,

I have created a form with 3 subforms. This form is split in to 3 parts on a 3-page tab control.

I want the user to enter data in the order below. All fields are required. My problem is that Access97 wants all fields of the main form to be completed in the order set by the table. ie. before I fill in a sub form. I have tried setting the form tab order property but it is being overridden.

First page:
a) Complete first 6 fields of main form
b) Complete subform 1
c) Complete subform 2
Second page:
d) Complete 5th field of main form
e) Complete subform 3
f) Complete 6th field of main form
Third page
g) Complete three fields of main form

Any help appreciated,
Seth

View 1 Replies View Related

Order Entry Database Problem With Pop-Up Subform

Sep 6, 2005

I have taken the Order Entry database sample from Microsoft and have added a "Wizard" type interface.

Question) I'm having trouble understanding how to get more than one Feature applied to a single new service.

- For example, If I add a new SERVICE to an ORDER, and I need to add all available FEATURES to that SERVICE, how do I do that? *see my attached database & relationships. The form of FEATURES is also attached. I just want to be able to check off the ones that apply.
(is this many to many? I tried a junction table but can't make it work)

I would really appreciate some advice on my Forms, and definitely advice on my Table / Relationship structure.

ps: My tblServices use to be called tblProducts. I then added the tblCategories, tblPaid, tblTeleServ, tblLongDistRate, tbl800Serv & tblFeatures.

Thanks in advance for your help,
jlig

View 1 Replies View Related

Populate Form Field From Subform Entry

Oct 19, 2006

I have looked at multiple samples on this forum and others and cannot seem to get the result I want working.

Have main form TmLdr made from table of same name. Entries include ReqName and CostCenter. These same entries are on a subform. On the After Update event on the CoRecDt (main form), I want the name and CostCenter entered on the subform to populate on mainform. This subform will be filled out by the user once and as long as they are using their own machine there will be no need to re-enter their name.

I think that I am so close but just a touch away. I am attaching my DB with hopes someone can take a peak at it and let me know what I am missing. Thanks so much.

View 1 Replies View Related

Subform Data Entry Problem Blank Line

Jul 7, 2005

I have a main form where the user chooses a BoxID. There is a subform on this main form that has a relationship between BoxID on the main form and subform. The users are entering data in the subform and when they have entered 10 lines of info I have a message that tells them to start a new box (I could not work out how to do it any other way as I lack VB skills). The user closes the form or clicks add new record to create a new box. If I view the previous record there should only be 10 lines of information in the subform but there are 11 as it takes the blank line as a new record....

View 8 Replies View Related

Forms :: Subform Field Entry Creates A New Record

Oct 8, 2014

I have a main form with several tabs. One of the tabs is a subform with just one number control, driven by a select query. The control shows a number, and you can type in a new number, which then updates the field in the table.

BUT, the control then shows a zero, it has moved to a blank record. If you enter a number again, it will attempt to write it to a new record.

So how do I display the number, and allow a new number to be entered that will update the SAME record, and not moved to a new record?

View 1 Replies View Related

Modules & VBA :: Data Entry - Subform Creating Orphan Records

Feb 13, 2015

How do I display a more meaningful message instead of the cryptic error about having to enter data into blah blah blah. How can I trap that error and provide them a more meaningful message about entering data. I have tried the following;

Main form name frmPatientRecords
Sub form name DentalRecords Subform
Private Sub Form_BeforeUpdate(Cancel As Integer)
If Nz(tblPatientDetails!recordid, 0) = 0 Then
MsgBox ("sorry. Please complete the main record entry")
Parent.SetFocus
End If
End Sub

View 14 Replies View Related

Toggling Linked Subform Shows Parameter Entry Window Twice?

Mar 9, 2014

I have two subforms in a main form. book_sub and book order subform. there are various subforms which i toggle in book order subform window by changing their properties with command button on main form. here is the code -

Code:
private sub billq_click()
Me.BOOK_SUB.SourceObject = "BILLQ"
Me.BOOK_SUB.LinkMasterFields = "[BOOK ORDER SUBFORM].FORM![ORDER ID]"
Me.BOOK_SUB.LinkChildFields = "[order ID]"
private sub stock_click()
Me.BOOK_SUB.SourceObject = "stock"
Me.BOOK_SUB.LinkMasterFields = "[BOOK ORDER SUBFORM].FORM![BOOKCD]"
Me.BOOK_SUB.LinkChildFields = "[BOOKCODE]"

Now the problem is when i change billq to stock it shows parameter entry window with caption [order id] twice. after clicking ok it does toggle the form to stock. then when i click button for billq again it shows the same thing.

the code works fine except showing parameter entry window twice with every toggle.

View 2 Replies View Related

How To Update A Field In Subform When Main Form Is Data Entry

Sep 19, 2012

I have a mainform set to data entry to add records to TABLE1. I inserted a subform that shows fields from TABLE2. I have a field in TABLE2, let's say TBL2FLD1(NUMBER). I want to add TBL1FLD2(NUMBER) from TABLE1 in the mainform to TBL2FLD1 and update said field in TABLE2.

My problem is:

(1) I get a #TYPE! error when I try to add the two fields, which I have tried many, many ways (adding them together in the Default Value; creating an unbound field to hold the calculation and then putting that field into the Default Value of TBL2FLD1; ETC), and
(2) I don't know how to get the subform to update TABLE2. It seems like the control gets stuck in the subform. Is there a way to accomplish this without coding it?

View 3 Replies View Related

Forms :: How To Make Subform Filter Its Data From Date Entry Selection

Aug 17, 2014

In my main form, there is this date entry selection and a subform with data on it.

How can I make the subform filter its data from date entry selection?

I have already created a relationships for my tables

I created a query for this subform (should I need to?)

It does not refresh my subform or I do not know what to do?

View 12 Replies View Related

Modules & VBA :: Save User Entry As Part Of Hyperlink Then Display In Subform

Nov 21, 2014

I have a form with multiple textboxes and comboboxes that allow for user entry, and a subform displaying a table, where the entries from the form are saved and can be retrieved. It's basically a way of creating new task entries and editing existing ones from a single interface.

One of the fields is an "issue number" of sorts, which is a 5-digit code that identifies the task. We have a website where details of each task are stored, and the URL format is akin to this: [URL] ....

The functionality that I'm hoping for is that when the user saves the record, it will be saved as the full link address, by concatenating the static first portion of the address and the code entered by the user. However, I need the table to still only display the code, not the whole link address, and will follow the full address when clicked in the subform table.

View 2 Replies View Related

Forms :: Default Entry Into Subform Based On Data Entered In Main Form

Apr 23, 2014

I have a form that request the User to enter a Parcel ID number (99-9a-99-99aaa-aaa-aaaa). The sub form asks for the subdivision number, block number, and lot number. The subdivision number, block number and lot number are normally part of the Parcel ID number but sometimes they can be different. I want the sub form to fill in the Subdivision number, block number, and lot number as a default but allow the user to change the value if needed. currently the sub form will only show what is entered into the table itself if a change is made on the main form the sub form does not reflect the change.

View 3 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved