Results 1 to 7 of 7
  1. #1
    Join Date
    Aug 2002
    Posts
    78

    Unanswered: Connecting Forms to data

    Currently I have a db .

    It contains (watered down version)

    tblDogs
    DogID
    DogName
    SireID(Father)
    DamID(Mother)
    Sex
    Champion

    I am having a problem creating the form that will allow me to fill in this information however.

    I would like to do two things. First of all Add Dogs to the table (obviouisly) in this process I need the controls to First see if the Sire or Dam is in the table already. If they are then to add the DogID to the appropriate field for that Dog record. If they are not then I need the Dog (whether sire or dam) to be added to the Dogs table as a dog and their appropriate ID to match that dog record (whether sire or dam).
    Sometimes you know all parental information on a dog and sometimes you do not. (It is just like a family tree so sometimes research needs to be done.)

    I would like the Dog control to be a Txt box and the Sire and Dam to be drop down boxes (their contents should refer back to the Dogs table and return the values according to their sex e.g. Male Dogs in sire list and female dogs in Dam list.


    Secondly I need the font color for any dogs that are champions to appear in red.

    I have zipped what is my testing db (Access 97) and attached it to this post. Would anyone be willing to check it out. Someone has given me a hand to a certain point the form frmDogs works for looking at information however for ENTERING information it does not. I did have test information in the tblDogs but I deleted it for testing purposes on this form. If you are willing to help and need further information or the db that has the information in tblDogs please let me know.

    email is t_galownia@hotmail.com

    thank you so much for your time and all in advance.
    Attached Files Attached Files

  2. #2
    Join Date
    Sep 2002
    Location
    Land of OZ
    Posts
    173

    Re: Connecting Forms to data

    I have modified the database that you attached. I added some code to the Not In List event of both the Sire and Dam comboboxes. Give it a try.

    Originally posted by t_galownia
    Currently I have a db .

    It contains (watered down version)

    tblDogs
    DogID
    DogName
    SireID(Father)
    DamID(Mother)
    Sex
    Champion

    I am having a problem creating the form that will allow me to fill in this information however.

    I would like to do two things. First of all Add Dogs to the table (obviouisly) in this process I need the controls to First see if the Sire or Dam is in the table already. If they are then to add the DogID to the appropriate field for that Dog record. If they are not then I need the Dog (whether sire or dam) to be added to the Dogs table as a dog and their appropriate ID to match that dog record (whether sire or dam).
    Sometimes you know all parental information on a dog and sometimes you do not. (It is just like a family tree so sometimes research needs to be done.)

    I would like the Dog control to be a Txt box and the Sire and Dam to be drop down boxes (their contents should refer back to the Dogs table and return the values according to their sex e.g. Male Dogs in sire list and female dogs in Dam list.


    Secondly I need the font color for any dogs that are champions to appear in red.

    I have zipped what is my testing db (Access 97) and attached it to this post. Would anyone be willing to check it out. Someone has given me a hand to a certain point the form frmDogs works for looking at information however for ENTERING information it does not. I did have test information in the tblDogs but I deleted it for testing purposes on this form. If you are willing to help and need further information or the db that has the information in tblDogs please let me know.

    email is t_galownia@hotmail.com

    thank you so much for your time and all in advance.
    Attached Files Attached Files
    Mona
    ________________________________
    Life is too short to be sane or sensible. Weird people rule and normal people suck

  3. #3
    Join Date
    Aug 2002
    Posts
    78
    Mona:

    thank you so much for your help. It is muchly appreciated.

    I do have a question however if you wouldn't mind.

    When I originally opened the form is seemed to have updated the table dynamically, (meaning when the sire and dam were entered they would show up in the next record. ) I have Access 2K at home and had to convert.

    So when I put Star in as dog. Jake in as Sire and Shadow in as Dam and hit enter. I could have sworn that the next record was Jake automatically, maybe not as I was so excited that this was working. I can't tell you how much I appreciate it.

    I have to close the form to get Jakes record to show up.

    Is there a way to make the form dynamically update so you can continue to put the known information of the dogs in, without having to close the form?


    I hope this makes sense.

    Thank you once again . . . I can't tell you how much I appreciate it.

    t

  4. #4
    Join Date
    Sep 2002
    Location
    Land of OZ
    Posts
    173
    I am trying to understand this ....

    You put in star as the dog name
    then you put in jake as the sire .... was jake already in the system? If not, jake's details will automatically be entered into the table with his sex set to 2 and the dogname set to jake.

    However if at this point you want to enter jake's details into the system, instead or star, then you would have to launch another form over the top of this ...

    YOu will end up in a never ending story .... of multiple forms ... whereby you may need to enter another dog as jake's sire who is not in the system ... calling yet another form to complete star's grandfathers details...
    Am I making sense.... anyway I will look into this option, but let me know if this is what you are looking at doing ...


    In the land of oz it is beer time so it will tomorrow that I will reply to your response...




    Originally posted by t_galownia
    Mona:

    thank you so much for your help. It is muchly appreciated.

    I do have a question however if you wouldn't mind.

    When I originally opened the form is seemed to have updated the table dynamically, (meaning when the sire and dam were entered they would show up in the next record. ) I have Access 2K at home and had to convert.

    So when I put Star in as dog. Jake in as Sire and Shadow in as Dam and hit enter. I could have sworn that the next record was Jake automatically, maybe not as I was so excited that this was working. I can't tell you how much I appreciate it.

    I have to close the form to get Jakes record to show up.

    Is there a way to make the form dynamically update so you can continue to put the known information of the dogs in, without having to close the form?


    I hope this makes sense.

    Thank you once again . . . I can't tell you how much I appreciate it.

    t
    Mona
    ________________________________
    Life is too short to be sane or sensible. Weird people rule and normal people suck

  5. #5
    Join Date
    Aug 2002
    Posts
    78
    Mona. . . Have a good time in OZ

    Sorry for the confusion. Let me try this

    I am hoping that after you get the last field filled in or preferrably after loosing focus from the field, and confirming that you want to add the dog who is not in the database, that the table will update dynamically.

    At this time inputting the first record. Star would be dog one, Jake (sire) is dog two and Shadow (dam) is dog three. after filling in Shadows name and confirming that I want Shadow added also. . it goes to a blank record number two. (Which preferably should actualy go to record number two being Jake.)

    To do such at this time, I have to close and reopen the form. (I am so excited you got this working for me and can't tell you how much I appreciate it. I have been trying to learn more about databases and am hoping to get to class this coming semester. But in the process of learning things (normalizations etc) I have revamped this so many times. I have been working on and off with this for a little over a year. I could get everything else I need to work properly except for this so I started over and am trying to get this to work before I finish. Once I pass this hurdle I am pretty much home free. I can do simple databases etc but I really picked a looloo of one to start from ground up to learn huh? (I have been to classes etc but have not worked with db's and Access enough to retain the information I learned. Thus this personal project so I can learn and attempt to retain.

    Is there a realtively simple way of getting the table connected to this form to update dynamically so the data can be entered continuously without having to continually close and reopen the same form without using other forms???

    Thank you for all your help. I really appreciate it.

    Thomas

  6. #6
    Join Date
    Sep 2002
    Location
    Land of OZ
    Posts
    173
    Hi Thomas,

    I believe that with a bit of programming ... we should be able to tweek this. Let me mull this process over and might have some solution for you in the next couple of days.

    Glad it is a dog database ... maybe I can start a database of my own to follow my mutts family tree ....

    Mona

    Originally posted by t_galownia
    Mona. . . Have a good time in OZ

    Sorry for the confusion. Let me try this

    I am hoping that after you get the last field filled in or preferrably after loosing focus from the field, and confirming that you want to add the dog who is not in the database, that the table will update dynamically.

    At this time inputting the first record. Star would be dog one, Jake (sire) is dog two and Shadow (dam) is dog three. after filling in Shadows name and confirming that I want Shadow added also. . it goes to a blank record number two. (Which preferably should actualy go to record number two being Jake.)

    To do such at this time, I have to close and reopen the form. (I am so excited you got this working for me and can't tell you how much I appreciate it. I have been trying to learn more about databases and am hoping to get to class this coming semester. But in the process of learning things (normalizations etc) I have revamped this so many times. I have been working on and off with this for a little over a year. I could get everything else I need to work properly except for this so I started over and am trying to get this to work before I finish. Once I pass this hurdle I am pretty much home free. I can do simple databases etc but I really picked a looloo of one to start from ground up to learn huh? (I have been to classes etc but have not worked with db's and Access enough to retain the information I learned. Thus this personal project so I can learn and attempt to retain.

    Is there a realtively simple way of getting the table connected to this form to update dynamically so the data can be entered continuously without having to continually close and reopen the same form without using other forms???

    Thank you for all your help. I really appreciate it.

    Thomas
    Mona
    ________________________________
    Life is too short to be sane or sensible. Weird people rule and normal people suck

  7. #7
    Join Date
    Aug 2002
    Posts
    78
    WOW Bless your heart., . . thank you so much. I have been working on this for so long and this has been my major stumbling block.

    Thank you so much for your help

    t

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •