Search results

  1. P

    How to reference a combo box on one form from another form.

    I have two forms, frmEdit and frmAddInmate. On frmEdit there are 2 comboboxes. The first combo box (cmbLogNum) is a list of incidents and from this combo box, the second combo box (cmbCDC2) is populated with the related data to the first combo box. This is what I need: I want that when the Not...
  2. P

    Public Variable and updating form

    I don't quite follow. I think this is what you are saying. You suggest that in tblOffense, I rename the field from CDCNum to InmateID. I don't understand the part about using it as a ForeignKey.
  3. P

    Public Variable and updating form

    Rural Guy you are pretty close there. tblOffense is used for the offenses, there can be many offenses with the same log number (one for each inmate involved in that incident Log Number) and yes one inmate can commit many offenses. tblInmate is for the data for each inmate. CDCNum is a unique...
  4. P

    Public Variable and updating form

    Yes, flgNil is a global variable set in a module used to determine if a new record was entered.
  5. P

    Public Variable and updating form

    Here is the NotInList code: #Private Sub cmbCDC2_NotInList(NewData As String, Response As Integer) Dim Reply As String Dim Temp As String Reply = MsgBox("Do you want to add this CDC Number to this incident?", vbYesNo, "Confirm Add new record") If Reply = vbYes Then...
  6. P

    Public Variable and updating form

    Well, first to Rural Guy. I did open the form in acDialog mode and put in the Response = acdataErrAdded but this did not work properly. And for ajetrumpet. I thought that declaring the variable would reset it but that it ony resets upon the form opening and should have worked...Creating a module...
  7. P

    Public Variable and updating form

    I have 2 problems with my DB I have been trying to resolve. Problem 1: I have a form (frmEdit) that has a combo box (cmbCDC2) on it. I have the NotInList property set to open a new form (frmAddInmate) to add the new data. I have set a Public boolean variable (flgNil). When frmAddInmate is...
  8. P

    Problem updating combobox

    Thanks Adam, I appreciate your help and did some research. I added a public variable (flgNil) to indicate whether a record was added (the isnull DLookup did not work and I figured this was easier) When frmAddInmate opens flgNil is set to false. Then if a record is added it is set to true and...
  9. P

    Problem updating combobox

    I have a form (frmEdit) with 2 combo boxes. The first combobox (cmbLogNum) is used to filter the contents of the second combobox (cmbCDC2). I have a notinlist event for the cmbLogNum to open e new form (frmAddIncident) to add a new record to the database. The new record is added and...
  10. P

    populating a text box from another form

    ChrisO, I don't quite understand what you are telling me to do. It appears that is is working right Thanks. Please give me input on what you told me I should do! you have been a great help!
  11. P

    populating a text box from another form

    Thanks, both methods worked but created another problem. Here are the issues with each one. Chris0--- The Open Args works but when the form closes, the combobox is not updated with the new information. I tried to do a Requery on the combobox in the NotInList event and upon exiting the...
  12. P

    populating a text box from another form

    I have a form that when someone enters data that is not in a combobox (cmbLogNum) the NotInList event is used to open a new form (frmAddIncident). I want a text box (txtIncident) in the current form to be populated by the data from the combobox (cmbLogNum) on the first form (frmEdit). I used...
  13. P

    Bookmark problem

    Excellent Bob, That seemed to do the trick! Now on to the forms to add new information....I hope I am able to get this running on my own....if not, I will be back. You were a great help! Thanks a million
  14. P

    Bookmark problem

    new error I recieved an error when trying to run the program. Here it is: Your Microsoft Access Database or project contains a missing or broken reference to the file "msadomd.dll" Version 6.0. I am attempting to find a fix online, I am a little leary of installing things from unknown sites but...
  15. P

    Bookmark problem

    I see your fixes, but when you select a CDC # it doesnot populate the box on the Left side of the form.
  16. P

    Bookmark problem

    Try this...Now I am confused OK...I decided to set it up and post the DB....In setting up data this is what it appeared....at first. Everything works fine if you select the first item in the cmbCDC combo box...then I added some data and it didn't work for the new incident, but some worked for...
  17. P

    Bookmark problem

    OK done...same error
  18. P

    Bookmark problem

    After a closer look and adding the code, and looking at the posts, I might not have been clear where the error message comes from. I get the error message in the following code: rs.FindFirst "[ID] = " & Me.cmbCDC rs.MovePrevious ' I had to put this in because it was always one item forward of...
  19. P

    Bookmark problem

    I didn't before but I just did....I still get the "value isn't valid for this field" error. I did not get the message box either.
  20. P

    Bookmark problem

    A little confused The row source type of cmbCDC is Table/Query...I have a query to populate the cmbCDC. I didn't find a recordsource or anything that mentions lookup tab. I know on tables there is that option for lookup and all text fields are set to Textbox. I guess I am not looking in the...
Back
Top Bottom