Strange Combobox Behavior

May 28, 2006

I have a form with a subform which contains a combobox in one of its fields. What's buggin me about this subform is that when I enter two records in it, successively, the first record seems to save without problem, but the second one will not allow me to select any item from the combobox. The combo displays the choices but when I select one, nothing happens and the field remains empty.

Note: just now I discovered that the combobox "locked" property turns to TRUE for the succeeding record, thus the uneditability. I'm still trying to find out what made it so.

View Replies


ADVERTISEMENT

Strange Combo Box Behavior

Apr 5, 2005

I've never seen this before.

I have a form bound to a non-updateable query. There is an unbound combo box in the form footer.

When the form contains no records, the combo box display goes blank after you make a selection. I checked the After Update event of the combo box and the value selected is still intact but it will not display it in the actual box on the form. I've tried Me.Refresh, Me.Requery, nothing works.

If the form contains records it works just fine but often times this form may not show any records when it is first open.

Check out the attached sample DB. Can anyone explain this one?

Thanks.

View 4 Replies View Related

Strange Behavior Adding Records

Aug 31, 2005

My client wants a data entry application, but he wants the previously entered data to remain on the screen since he usually only wants to change a couple of the data fields. So, I created a form (.mdb) and add the record via vba code.

I have the autonum field turned on and have set the form parameters to:

edit = no
delete = no
additions = yes
Data Entry = yes

Now, say the next autonum should be 50. When I add a record, the autonum used is 51 and as I continue adding records, the autonum increases properly. However, when I close the form (via the X or via a close button) record number 50 is created with the exact data in the last record added.

I can filter this out with a distinct query, but I really don't want this data and so far I have been unable to stop this from happening.

Does anyone have any idea as to what is really going on here?

View 1 Replies View Related

Strange JOIN And Strange Realtion Of Tables

Sep 9, 2005

I have a table called 'students' with the appropriate fields. There is another table named parents_prof which contains records of common professions. The tables are related through the 'ID_parents_prof' of the 'parents_prof' table to two fields on the table 'students', thus 'students.father_prof' and 'students.mother_prof'.

1st question) Is that possible? Is it possible to create a relation between the key field of one table to two different fields of another table? Is it a good practice?


I did this because I want to build a query which checks for both fields together, meaning I want Access to return a record if the appropriate profession is in either field of mother's or father's profession.


SELECT students.surname, students.name, students.father_name, students.father_prof, students.mother_name, students.mother_prof

FROM parents_prof INNER JOIN students ON (parents_prof.ID_parents_prof = students.mother_prof) OR (parents_prof.ID_parents_prof = students.father_prof)

GROUP BY students.surname, students.name, students.father_prof, students.mother_prof, parents_prof.parents_prof

HAVING (((parents_prof.parents_prof) Like "*" & [enter profession] & "*"));


Access cannot represent the above graphical, so I had to enter the

OR (parents_prof.ID_parents_prof = students.father_prof)

in the SQL formula.

2nd question) Is the above proper query, according to the rules?

View 11 Replies View Related

Odd Behavior

May 30, 2006

I imported some db objects from one db to another. I worked on the db, with the imported files, to make a new db. However, while working on the db suddenly, I lost all the imported files, as they were not visible via the objects panel.
What a revolting development this was!! All that work for nothing. I reimported a Form from the other db into the one I was working on and-WOW! All the objects showed up in the Object panel as they should. I find that importing from the other db always makes the Objects visible, so the effort was not for naught.
Does anyone know why Access 2003 behaves in this ridiculous manner? It is a real pain in the a--, but can be worked around.

View 1 Replies View Related

Form Behavior

Mar 6, 2006

I have a form that I have added drop down combos. I want the form to open with drop-downs blank, they keep populating. Is there a setting that could do this? Thanks

View 2 Replies View Related

Combo Box Behavior

Jun 9, 2006

I have a split db with the backend on a shared drive. I have two combo boxes on my form that are filled with a sql statement from two different tables - one is "manager" and one is "owner". When I open the front end on my system both combos are loaded with the correct data. Lately when I open it using one of our dedicated computers in a conference room the "managers" combo is completely empty. The "owner" one and any others are fine. I can't figure out what could be happening to make it just lose the one. Has anyone experienced this before?

Thanks,

Toni

View 1 Replies View Related

Access Behavior With SQL Backend

Jul 6, 2007

I'm currently researching on how to best migrate from Access back-end to a SQL backend, and was able to find wealth of information on how well Access can play with various SQL servers, how ODBC drivers are implemented, and how JET handles queries to backend. If this helps matter, I'm considering using MySQL as a backend.

That said, there are some gaps in my research that I'm hope someone will be able to fill in for me.

1) I have couple of queries that may use Access's custom function not otherwise supported in SQL servers. If I based the query on otherwise executable query, would JET be able to pass the sub query to SQL, and get the recordset and apply the next query using custom functions without any problems?

2) In general, DAO is best when you're using JET, but ADO is best for ODBC. I'm not clear whether it's possible to use a mixture of ADO and DAO, provided I've disambiguated the library (which I already did anyway) to make even efficient use of recordset. For example, I'd use ADO to work with data from backend and once it's bought over here, switch to DAO for faster handling by JET. Is that possible *and* advisable?

3) I found lists about limitations or problems that may arise due to differences between Access and SQL, which is good to know. However, I never found any answer as whether VBA may cause problems with using SQL data. Let's say I have a form that has lot of VBA coding to handle calculations, multiple selection in listbox to be added to a junction table, dynamically changing rowsource for a combobox, whatever that is based on a query that otherwise runs fine with SQL server- will the form still work just as fine or are there going to be any surprises after migrations?

4) Somehow related, if this is supported by whatever SQL server I may use, would I be better advised to use stored procedures in place of VBA for Access forms?

Thanks for your feedback. :)

View 14 Replies View Related

Trigger Like Behavior In Access

Dec 23, 2004

I'm not sure if this is the proper forum for this post. I have a database in access in which i need to mimick a trigger like behavior. As far as I know access does not support triggers. When a user updates a record I need a LastModified date field to be updated with the current date automatically.

I've seen several examples of how to accomplish this using forms, however, the users of this database do not use forms. They are editing the records by hand by opening up the table and simply typing.

Any help you can provide is greatly appreciated.

Thanks!

View 3 Replies View Related

Weird Field Name Behavior

Aug 4, 2005

Hi all,

I use to have a field named RDI_ID, later on I decided to change the name to RDI to make things easier.

I have several macros pulling recordsets, but they stopped working, even though I have changed that field name
to RDI in the macro as well.

Curiously, they do work when I change it back to the old name, being RDI_ID. I have been looking at that field
propriety and it is named RDI. Did I miss a change somewhere?

That table has no relationship whatsoever.

Help plzz.

View 2 Replies View Related

Weird Field Name Behavior

Aug 4, 2005

Hi all,

I use to have a field named RDI_ID, later on I decided to change the name to RDI to make things easier.

I have several macros pulling recordsets, but they stopped working, even though I have changed that field name to RDI in the macro as well.

Curiously, they do work when I change it back to the old name, being RDI_ID. I have been looking at that field propriety and it is named RDI. Did I miss a change somewhere?

That table has no relationship whatsoever.

Help plzz.

View 4 Replies View Related

Form Closing Behavior

Mar 14, 2005

Not sure what to call this "phenomenon" so haven't had any luck searching for an answer.

I have a form (form1) that has a close button with code behind it. When the button is clicked, it takes a few seconds for the code to run. When form1 closes, all is well up until: There is another form (form2) that is open behind form1. When form1 closes, part of it is still visible over form2.

Hope this makes sense. Any way to solve?

View 1 Replies View Related

Wierd Subform Behavior (Please Help)

Dec 29, 2005

When I open my mainform through an onClick event of a button, the form opens up with the subform on it is disabled/closed -- Just a blank white box shows in place of the subform on my mainform. Here:
http://img426.imageshack.us/img426/4672/shot29sj.th.jpg (http://img426.imageshack.us/my.php?image=shot29sj.jpg)

However, when i go through the objects window and open the mainfrom directly. I am able to enter and update data and the subform shows up and works fine. Here:
http://img420.imageshack.us/img420/5650/shot19ig.th.jpg (http://img420.imageshack.us/my.php?image=shot19ig.jpg)

This is the code attached to the onClick event on the mainMenu

Private Sub New_Project_Click()
On Error GoTo Err_New_Project_Click

Dim stDocName As String
Dim stLinkCriteria As String

stDocName = "Project Status - Full Details2"

stLinkCriteria = "[projectId]= 0"
DoCmd.OpenForm stDocName, , , stLinkCriteria
[Form_Project Status - Full Details2]![Proj ID].Enabled = False

Exit_New_Project_Click:
Exit Sub

Err_New_Project_Click:
MsgBox Err.Description
Resume Exit_New_Project_Click

End Sub

This is the record source on the mainform:
The projectInfomation table is the record source
SELECT *
FROM projectInformation;

This is the record source on the subform:
The projectStatusCommentary table is the record source

SELECT projectStatusCommentary.projStatusId, projectStatusCommentary.projectId, projectStatusCommentary.statusCommentary, projectStatusCommentary.commentaryDate
FROM projectStatusCommentary;


The link fields are:
projectInformation.projectId
projectStatusCommentary.projectId

The tables are in sybase and my application has an ODBC connection to them.
I can update any of the tables directly without issues.
I have ran the queries independently and updated tables through the query and it works fine also.

I have been pulling my hairs out on this for over 3weeks now. cos i can't seem to find what's wrong.
I am not able to attache the db cos it's very huge. But i have copied the problematic form &subform, to a new db so you may see my design, and record sources.

If you have any suggestions, ideas, or you've come across this kind of issue before, anything...please make my new Year a happy one and help :)
I would really appreciate it!
Have a happy and prosperous new year.

Yours truly,
Frustrated one

View 10 Replies View Related

Odd Behavior On Form Labels

Aug 18, 2006

I have a form with a few labels that for some reason, very often will have a strange looking line above them after I am done clicking on them. I can't seem to find out why this happens. It happens on every label on this particular form.

Please take a look at the attachment for a screenshot.

I'd appreciate any advice you may have on why this happens and how to fix it.

View 5 Replies View Related

Weird Addrecord Behavior *help*

Jan 8, 2005

I have an insert into statment that takes information out of textboxes and adds it to a different table.


Code: DoCmd.SetWarnings False If Not IsNull(Text96) Then DoCmd.RunSQL "INSERT INTO walkers (Walker, Firstname, Date, Lastname, Visits) VALUES('" & Text96 & "', '" & Firstname & "', '" & Lastname & "', '" & Date & "', " & Text98 & ");" Text96.Value = Empty Text98.Value = Empty End If


It works but when I add the Vaule of Date I get an error.

Run-time error 3134

Can anyone see any syntax errors or what im doing wrong....
Thanks

View 3 Replies View Related

Peculiar Date Range Behavior

Oct 21, 2005

I have a form that is based on a query that requires the user to choose a start date and end date for the data to display. The query looks to the text boxes on the form for the criteria for the date field (between .... and .....). For some reason, when you select the same start and end date, it won't display data even if there are records for that date. Selecting a two day range will display it, but not one. Why is that and how do I get around it??? :confused:

View 3 Replies View Related

Weird Query Select Behavior

Nov 13, 2006

Help!

I have one table that deals with project details. Then I have one table that deals with project history. Obviously each project has a bunch of unique details and several related records detailing the project history.

My goal is to be able to read details of any project along with the last history entry.

1-I have one query that gives me the last history comment. It creates a table.
2-Then I have another query that gives me the details of the project along with all the project history. It creates another table.
3-Then I have a select query that joins the first table and the second table comparing the project history comments and only showing the records that have the same comment. Therefore I get exactly what I need; The details of a project along with the last history comment.

The problem: I get the correct records selected, however 1) if the first entry in the project history table in one or several records is one word, then the query results include those records repeated a random numebr of times. 2)If the first entry in the project history table in one or several records is two words, then the query results include those records repeated a random number of times, but less times. 3) If the first entry in the project history table in one or several records is three words, then the query results include those records repeated a random number of times, but only a few times. 4) If the first entry in the project history table in one or several records is three words or more (on average), then the query results include only the record I wanted once.

What is going on?!??!?!?!

It almost looks like the query is runing once and again until a certain number of words are compared....

This is weird.

Anyone has any idea?

thanks

mafhobb

View 2 Replies View Related

Query Behavior Acess 2003

Aug 31, 2007

I've just started using 2003 and had a query give me incomplete results. One table contains 6 numbers stored as text joined to the corresponding code in the data set table. Both fields are formatted as text. When using the table as criteria I do not get all of the expected records, I had to type in("1000", "2000",...) in order to retrieve all of my data.

Any ideas on what could be happening?

I use the text setting to avoid problems importing the data set which begins life as a csv file.

View 1 Replies View Related

Bizarre Behavior With Listview StartLabelEdit And Multiselecting

Aug 14, 2007

This is driving me crazy! I have some code that has a list of items in a listview. When I right click it shows a pop-up right click menu with a macro. Then I select an item in the list that says Rename. After ensuring a single element is selected the StartLabelEdit method is called on my list view. Then I can begin editing. Normally this works fine. However, if I first double click a list item. Then I enter my double click list view event handler and from there I open a form. Later if I close that form and then try right-clicking and selecting rename. This time after StartLabelEdit is called, the BeforeLabelEdit event is never called. The whole selected line blinks momentarily and then wherever my cursor is at that moment every item between it and the originally selected item becomes selected. If I move my mouse around the selection changes to be between the originally selected item and the one my mouse is over as it moves. It's as though I had clicked the left mouse button down but didn't let go of it and then started moving the mouse around. If I left click and release again it seems to get out of this mode, but I am still not able to ever manually invoke the StartLabelEdit method after this point. If I close the form and re-open it, it works fine. (I've tried calling refresh on the list view but this had no effect.)

Here's the really weird part. If instead of double-clicking to open a form, I right click and select a menu option to call the exact samed double click event method. Everything works fine as you would expect. Then I tried another test. I made the double click method call another method to open the form. When I did this and tried the same alternate way of opening a form, it did not work and the same original error occurred again. This weird behavior is bizarre and I have no real idea how to troubleshoot it any further.
:mad:

Has anyone ever seen or heard of something like this where StartLabelEdit goes haywire? Please help me if you can.

Thanks...
-Will

View 1 Replies View Related

Quirky Setfocus Behavior In Afterupdate Code

Jan 8, 2005

Hi -

I have a form with a subform in a datasheet view. They are arranged in a one-to-many relationship (It is an order header and then order detail setup). I am trying to get it so if a user updates a particular field (QTY) in the subform (which is in datasheet view), they must also update another field (SelectSize) in the same record. I have created an 'AfterUpdate' event for the QTY field. In it I have:


----------------
Private Sub QTY_AfterUpdate()

Forms![OrderForm]![OrderSubForm]![SelectSize].SetFocus

End Sub
--------------

The problem is if I already have data in the subform (e.g. 5 records), and I go to update the QTY in record #2, when the setfocus command runs, it puts me in the SelectSize field in record #5 instead of record #2. It doesn't matter what record number I try to edit, it always puts me in the SelectSize of the last existing record number. I have tried replacing "Forms![OrderForm]![OrderSubForm]![SelectSize].SetFocus" with "Me![SelectSize].SetFocus", but unsurprisingly, this does the same thing.

Does anyone know how to make the setfocus stay within the same record?

I am using Access 2003 (11.6355.6360) SP1.

Thank you,
John

View 3 Replies View Related

Search Form Enter Button Behavior

Jun 9, 2006

I have a search form from which the user can search by multiple criteria.
Currently users run the search by pressing a button on the form with the mouse, the keyboard enter button just tabs around the form.
My question is can I get the enter button to run the search rather than tab around the form?
If so how?

Thanks.

Larry.

View 1 Replies View Related

Very Strange

Apr 27, 2005

I have done some forms and it is the first time that i had this problem:
I can input data in several records without having any problem but when i close and save the form and next time i open it ,i do not find my previous records. I checked this in the tables and find that the values that i had input were there but in my form these values had disappeared. Can anyone explai this ..


Also,

Suppose i have 2 tables with NAME set as the primary key and which is linked 1-1. When i create a form for these 2 tables and when i write JO in the name field only once the name JO should automatically be inserted in the other name field i.e i should be able to input only one data. This is not the case. What i should do is : write JO then click in the other NAME field then type something e.g RO then this will be typed auto. in the other Field. Can you also explain this

View 2 Replies View Related

Strange Bug

May 27, 2005

I have a form with a tab control and each tab has a subform on it. 3 of these tabs/sub forms are continuous forms that allow the user to enter details for the selected job (i.e. on tab has a subform that allows the user to enter various scheduling dates for the job).

If I say have the scheduling tab selected and then change a field in the MAIN form, then click on the new record row in my continuous subform my main form jumps to the first record. However, if I update a field in the main form, select a different tab, then click on the new record row in my subform it works fine. Also, if I click the add record button it works fine as well.

I can't seem to find anything in my code that would cause the jump. Any ideas?

Thanks,
Hammy

View 3 Replies View Related

Forms :: Update Row-source Of Combobox Based On Value Selected On Another ComboBox?

Apr 26, 2015

I am trying to use a combobox called Manufacturer to select which table the combobox called Model gets it's rowsource from using the code below.

Code:

Private Sub Manufacturer_AfterUpdate()
If (Me.Manufacturer.Value = "Siemens") Then
Me.Model.RowSourceType = "Table/Query"
Me.Model.Recordset = "SeimensTable"
Me.Model.RowSource = "SELECT Model FROM SeimensTable"
Else
If (Me.Manufacturer.Value = "Samsung") Then
Me.Model.RowSourceType = "Table/Query"
Me.Model.Recordset = "SamsungTable"
Me.Model.RowSource = "SELECT Model FROM SamsungTable"
End If
End If
End Sub

But when I run the form and select Manufacturer. Combobox Model remains empty. tell me what I'm doing wrong?

View 5 Replies View Related

Saving Contents Of Combobox As String, And Inputing In Another Combobox

Jan 13, 2005

How would I modify multiple comboboxes in subforms at the same time. For example.. In main form ComboboxA user selects 1992, Combobox1 in subform1 is also changed to 1992, as well as Combobox2 in subform 2.

Whats the best way to do this?

View 2 Replies View Related

Very Strange Error

Oct 4, 2005

I received a very strange error this morning.

I was going to create a new query with the simple query wizard, but as soon as selected a data source I got a message saying "The expression on Got Focus you entered as the event property setting produced the following error: The text you entered isn't an item in the list."

After this I can select a datasource, but the cursor remains in hourglass mode. It almost seems like this is a run-time error, when I am merely trying to create a new query. In addition to which, I haven't set any events to run on "got focus". Anyone have any ideas on what is causing this and how it can be fixed?

Thanks,
Chris

View 3 Replies View Related







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