Forms :: Unbound Form With Bound Listbox
Jun 2, 2015
My code is not working.
1. The code below should equal the Current Month
2. It does not close the form if no data.
PHP Code:
If DLookup("[CurMonth]", "tblEmpEvaluation") = Format(DateSerial(Year(Date), Month(Date), Day(Date)), "mmmm ")
DoCmd.OpenForm "frmEvalNotice"
End If
PHP Code:
If DLookup("[CurMonth]", "tblEmpEvaluation") <> Format(DateSerial(Year(Date), Month(Date), Day(Date)), "mmmm ") Then 'No Data. NotWorking?
DoCmd.Close acForm, "frmEvalNotice"
End If
View Replies
ADVERTISEMENT
Mar 24, 2006
Please help,
I have a form with a subform in it. The main form has a combobox, called vendor. The subform shows all software.
When i select a vendor, i want only the software for that vendor to show in the subform.
What I am trying to do is set up the link child fields and link master fields so that this works. However, i am getting an error saying, 'Can't build a link between unbound forms'.
I have checked to make sure that relationships exist between the vendors and Software tables but the problems persist.
What should i do here???
View 1 Replies
View Related
Sep 27, 2006
Hi all,
My current database (built with a lot of help and sample code form this site..thankyou to all for their advice) tracks the escalations we receive into the business but as we have used it more and more I have started experiencing a massive performance issue.
I basically have a main table that captures the basic details, reference, product, escalation source, escalation reason etc, and these are captured from combo box selections (so only capturing the id numebr of the row in the combo box)
My main problem seems to be a table I have that we have linked, via the unique escalationID, that we cna add notes for each escalation.
So for instance a particular escalations can 1 or 50 notes (or more) depending on the work involved to resolve.
This table now has thousands of entries and is about 10Mb on it;s own.
It seems that when I open my bound forms the query is having to scan not only the main table, but also all of the notes in the journal table.
My question is,
Would I be better to -
1 - Use unbound forms and pull the data via a recordset call or
2 - could I use a query that captures everything for only the open escalations and then have my main form query that query or
3 - have the form load but do not link the journal table and have the form pull the data in seperately ?
Hope that makes sense and appreciate any help on this one.
MattP
View 6 Replies
View Related
Nov 8, 2005
I'm having a bit of a problem - I built quite a complex db that works great and I'm comfortable with code and access. But, I've been working with ASP for a while now and I think it has made me a bit fogetful re: Access.
If someone can point me in the right direction conceptually it would be appreciated. My system is primarily built around scheduling and I have created tables and web forms to interact with my current access database to allow our recources to check and confirm their daily schedules online.
My problem is on the Access side. I need to build a dashboard using a form that queries the table that holds our resources status information and will display whether or not they've logged in and confirmed their schedule. As well, I need controls on this form to allow me to update their individual schedules if it has been changed. Most of this is no problem, the big problem I'm having is the display of information and form interaction... Can I use a continuous form for this?
When I try to use unbound controls such as images - hiding/unhiding images depending on a specific records value (for let's say a traffic light that shows whether a resource has confirmed their schedule) - it seems that I can't control images, checkboxes, etc. for individual records on the continous form with code as all these unbound controls defualt to the value of the first record.
View 3 Replies
View Related
May 12, 2014
I have a list box bound to a query. If the list box retrieves two records, I am not able to select only one of them. If I click, it gets both records selected ( highlighted ). Is there any way I can select only one record?
View 8 Replies
View Related
Aug 20, 2013
I want to be able to edit an unbound listbox. The box consists of two cloumn, PersonsName and NoOfDogs. The PesonsName is would be edited from the Contacts form if it needed editing, which is fine as would the number of dogs that they owned. The listbox is on a form that shows how many people are going to an event and how many dogs each person is bringing with them (not always the amount that they own).
When the person says that they are attending an event they may not, at that point know how many dogs they are bringing so the user would update that information later. The easiest place to be able to do that is by editing that coloumn in the listbox. I understand that this means editing the table that feeds that listbox which is fine.
I just want to simply be able to click on the name in the listbox and edit the No Of Dogs for that person.
View 4 Replies
View Related
Nov 5, 2012
I've created a data entry form w/ 7 fields.... [f1], [f2], [f3], [f4], [f5], [f6] are bound to a table. While [f7] is unbound and has Nz function.
Now, the value of [f7] is the summation of [f1] to [f5], i want that what ever value is generated by [f7] will be stored on [f6] in both forms and table...
View 1 Replies
View Related
Jan 19, 2006
hey all i was wondering, can a unbound text box be a bound textbox. I have just noticed that my unbound text box doesnt not save in the field in my table, that is because it is unboune right? but i need it to save to my table, and i guees the only way to do that is to save in in the save button right? thanks
View 2 Replies
View Related
Jan 19, 2006
hey all i was wondering, can a unbound text box be a bound textbox. I have just noticed that my unbound text box doesnt not save in the field in my table, that is because it is unboune right? but i need it to save to my table, and i guees the only way to do that is to save in in the save button right? thanks
View 9 Replies
View Related
Apr 24, 2014
I have an unbound listbox on a form which displays a list of staff, both past and present, based on an SQL query.
I want to be able to differentiate between current and past staff using different colors, i.e. Black text for current employees and red for employees who have left, based on a field (True/False) in the original staff table.
View 4 Replies
View Related
Apr 21, 2015
I have 2 fields in an MS Access form "BTKForm" sending and picking up data form a bank terminal.
Code is executed by clicking a Button on the form.
Field 1, "IssuerID", is an Unbound field picking up a code from the bank terminal. It's numbers between 0 and 100, representing the Card provider.
Field 2 - "IsID", is a value field linked to a table.
I want to take care of (save) (copy) "IssuerID" in to "IsID".
Code:
Public Sub TransferAmount_Click()
Set BAX = CreateObject("BankAxeptSrv.BankAxeptAutomation")
If BAX.Connected And BAX.LicenseVerified And Not BAX.BankMode Then
Dim amnt As Long
Dim cashb As Long
amnt = Round(Amount.Value * 100)
[Code] .....
View 12 Replies
View Related
Apr 17, 2006
hello guys
i have values in two unbound textboxes and now i would like to assign the sum to a bound textbox. Also need AfterUpdate event too.
Can any expert help?
Thank you
View 4 Replies
View Related
Aug 16, 2006
I have a form with several fields bound to a table, and also a listbox of records that are not bound to any table. What I want to do is to be able to double-click a record in my listbox and have the record show up on my form in a particular bound field, and also become a part of the underlying table's record.
Is it possible to do this? If it is, how would I do it?
Thanks in advance to all who are willing to help!
View 4 Replies
View Related
Aug 10, 2005
Hi
I've created a listbox and am using the following code
stWhat1 = "": stCriteria1 = ","
For Each vItm1 In Me!LstArchive.ItemsSelected
stWhat1 = stWhat1 & Me![LstArchive].Column(0, vItm1)
stWhat1 = stWhat1 & stCriteria1
Next vItm1
Me!txtCriteria1 = CStr(Left$(stWhat1, Len(stWhat1) - Len(stCriteria1)))
The problem is that my bound column is a text field. I'm really struggling on where to put my quotations so that I get the following with the In function
In('00638','00639').
Any help or pointing in right direction would be very much appreciated
Carrie
View 3 Replies
View Related
Feb 6, 2015
I have two listboxes. One for Activities and the other for Organizations.
I set the Org listbox to be multi-select so I could run a loop on that listbox to join multiple Orgs to a single Activity. That part works well.
To do so, I am using the bound column (which is the pkey value) from the multi select listbox, and on the single select listbox I'm using the ListboxName.value to gather the pkey for the "1" side of this 1:Many series of inserts.
Now... I want to use one of the other-than-bound-column value from the multi-select listbox, but I don't know how. When setting a value I only know of the use of :
Code:
ListBoxOrganizations.ItemData(varItem)
and I don't know how to do the equivalent of
Code:
ListBoxOrganizations.ItemData(varItem's column(2).value)
yes, I just made that up, but I hope you get the point. Meaning, as the loop cruises the ItemsSelected on the multiselect I'd like to use other than the bound column when setting variables.
I've tried using the column property to then cruise to the proper record in the listbox, e.g. :
[code]
txtCollaborationDesc = "Collaborate " & ListBoxOrganizations.Column(2, varItem) & " with " & listboxActivities.Column(2)
[code]
But this seems to return the column(2) value of the first record loaded into the list box, as if the varItem piece is being ignored. I believe the loop is working properly, as when the inserts are happening correctly with the bound column of the multi-select list is correctly present as an Fkey in the resulting child records.
I just can't get any other column's value for some reason.
MS Access 2010 and this is an accdb.
View 3 Replies
View Related
Dec 12, 2012
So I have a list box that lists organizations. I recently changed the list box type to extended multi select. On the same form, I have a button that opens a new form where the user can input contacts for each organization. When the list box was not multi select, the expression [forms]![media]!
[List30] made the default value of one of the fields in my contact form the bound column from the selection in the list box. However, now that the list box is multi select, the contact input form does not seem to be able to get the value from the bound column in the list box. When multi select is turned on, is the bound column stored differently.
To even get the contact input button to work, I had to change the code from:
Private Sub Command40_Click()
On Error GoTo Err_Command40_Click
Dim stDocName As String
Dim stLinkCriteria As String
stDocName = "Contactsqry"
stLinkCriteria = "[Organization ID]=" & Me.List30
[Code] .....
View 14 Replies
View Related
Dec 14, 2014
Using a popup form
1. On my main form, I have a listbox, I would like to edit the values of the listbox.
To do this, I have a popup form with 2 listboxes, one to have the values of the listbox on the main form, and the other listbox with option values for the 1st
1) how to i pass the rowsource sql of the listbox on the main form to the listbox on the popup form
2) how on closing the popup form, do i update the rowsource sql listbox on the main form from the changed value of the popup form listbox rowsource sql
View 3 Replies
View Related
Mar 22, 2014
I have 4 fields that are unbound on a form. img1 img2 img3 img4..When these are entered they are all combined and autofill another unbound textbox = imagename.. what i would like to do is from this unbound textbox 'imagename' ..i would like to populate a textbox that IS bound called FileName
[Event Procedure]
Private Sub imagename_Click()
Me.imagename = Me.FileName
End Sub
View 4 Replies
View Related
May 22, 2013
I have a form and subform. The main form shows some customer details, and the continuous sub form shows that customer's charity donations.The code below runs when the form opens, and binds ADO recordsets to the two forms. The binding appears to be successful.
However whatever I do I can't make the subform update correctly to show the relevant customer donations. For example, when I use the **'d lines to update the link child/master fields, I get a "Data Provider Could Not Be Initialized" error.
Code:
Private Sub Form_Load()
Dim cn As New ADODB.Connection
Dim rsCust As New ADODB.Recordset
Dim rsDons As New ADODB.Recordset
[code]...
View 7 Replies
View Related
Apr 17, 2015
I have a form based on a query. I'd like to add a search box to the top to look up values and then populate the rest of the form. I can't do it with the combo box wizard because the relevant (third) option doesn't show up, I assume that's because the form is based on a query not a table.
Any alternative method of adding a search?
View 4 Replies
View Related
May 26, 2015
I have a bound form that normally is opened via macro. Very straight forward just has the following in the where.
Code:
[userID]=[Forms]![Home]![txtSelectUser]
I'm trying to open the same form via doCmd.
Code:
DoCmd.OpenForm "frmUserInformation", , , "UserID=" & Me.txtProblemID
I've msgbox'd the txtProblemID and the correct ID is being passed. Where I fall into an error is on the frmUserInformation's onLoad event which uses the ID form the frmUserInformation.txtUserID box. The error I get is "Syntax error (missing operator in query expression '[fldUserID]='."
Code:
strEndMonth = DLookup("fldDateExpiration", "qryUserExpirationDate", "[fldUserID]=" & Me.txtUserID)
What I've narrowed it to is the timing between the docmd.openform and the onload of the form. I've tried changing the onload to be on activate - and it just opens empty.
how to get the docmd to open the form correctly before the onload tries to fire?
View 6 Replies
View Related
Sep 24, 2014
I have a number of forms that are bound to recordsets as follows:
Dim rs As New adodb.Recordset
sqlQuery = "Select * from myTable"
rs.Open sqlQuery, sqlCNN, adOpenKeyset, adLockOptimistic
Set Me.Recordset = rs
Set rs = Nothing
In Access 2003, users could open these forms and filter on basically any field by using the right click-> Text Filters functionality.
In Access 2010, this functionality appears to work (users can apply the filter and the Toggle Filter button in the ribbon shows a filter is applied), but all of the records are still visible in the form.
Any work-around that does not involve redesigning the form to be non-recordset bound?
View 4 Replies
View Related
Sep 2, 2013
I'm using Access 2007. I've created a table with two fields. "Novice and Recertification" as in combo box.
I put it on the form. Now the idea is when a user clicks Recertification, it shows up on the report. When the user clicks on Novice, it should be empty on report (Reason why I want to keep novice is so that we have a record of it.)
Now the challenge is I added another column, empty field for Novice and Recertification for Recertification. Thing is if I set the bound column, I select on an empty field on form and it will be empty on report. But I want the user to see Novice on the form and it must not show on the report.
View 3 Replies
View Related
Mar 20, 2013
So I'm not new to Access but I am to 2010. It has been a bit "challenging". Here's my first question:
1.) I'm trying to search on a field by using a command button. I basically want to click the button and the following message pops up: Enter MRN.
2.) When the MRN is entered, I would like the form to filter on all records that have this MRN.
3.) In old versions of Access, I would create a Macro for this and then call the Macro in the form.
4.) I've tried the FindRecord action in the Macro but it does not work. I actually came across several actions that don't seem to be working properly (getting error messages).
5.) In my head, this should be one of the EASIEST things to do. I've done this before in several different databases. I will admit it has been a few years since I have used Access for this (ie. building forms, macros etc.). I've primarly used it to pull in a data set and then run some queries to get the data I need quickly versus using Excel.
View 5 Replies
View Related
Aug 26, 2014
I have a form AddNewEquipment. This is bound to a table, EquipmentDetails.
EquipmentDetails has a Yes/No field, 'ParentChoice'. So when EquipmentDetails.ParentChoice = Yes, I want to open up a new text box, AddNewEquipment.ParentDescr, into which someone can put some text. This text I want to append as a new row in a different table, ParentList.ParentName. (that table also has an autonumber field)
I only want to do the save when I save the whole form.
Is this something like using an On Lost Focus event from the ParentDescr field which only invokes when the overall form save button is clicked? What would I put in the On Lost Focus event.
View 9 Replies
View Related
Aug 2, 2013
I have a report that generates 100 items in alphabetical order. All of the items are also displayed in a table. I have a bound form attached to the that table, and when the items appear they are not in alphabetical order. Therefore, it is a hassle typing in the data when the form will not appear in order, because instead of going in order I am flipping through pages. What is causing this to happen? And what can I do to fix this?
View 2 Replies
View Related