Results 1 to 4 of 4
  1. #1
    Join Date
    Sep 2004
    Location
    Tampa, FL
    Posts
    520

    Unanswered: append to a field

    I have an Access 2000 database.
    I have a table Client_Tbl.
    The table has a field Casenote
    I have a form Goal_Frm.
    I have a pet hamster Donkey_Pet.

    What I would like to be able to do is have my users input case note information on the form. Easy enough. However, I only want them to be able to ADD to what is already in the casenote field not change any previous info.

    I though I could set up a text box or the like and have what the user enter new case notes then have an update button that takes the text box entry ( a variale I assume) and adds the entry to the "casenote" field for the record being used.

    Does that make sense? How is this possible? Any ideas would be appreciated.

    Darasen
    Darasen

  2. #2
    Join Date
    Feb 2004
    Posts
    533
    Quote Originally Posted by Darasen
    I though I could set up a text box or the like and have what the user enter new case notes then have an update button that takes the text box entry ( a variale I assume) and adds the entry to the "casenote" field for the record being used.

    Does that make sense? How is this possible? Any ideas would be appreciated.
    This is pretty straight forward thing to do although there are a few different approaches you could take to implement.

    You will have your form displaying your data and casenotes. The Case notes field may be disabled/locked/ to prevent direct editing of the original note. Then you can have an unbound field where new notes are entered. When the note is applied you can take the new text and the original and concatenate them to combine the text. Like this.

    strOrgTxt = trim(Me!casenote)
    newTxt = trim(Me!newTxt)

    strTxtAppnd = strOrgTxt & " " & newTxt
    Me!casenote = strTxtAppend

    This is a very basic, I suspect it will lead to problems. For example: soon you will exceed the text limits for your field with long notes, You can not track user who entered the note or the date time of note entry...

    For a better solution create a table specifically for casenotes. call it "tblCaseNotes". Have fields for:

    caseNum|EntryBy|DateTime|Note|Type

    You can use this as a subform on a form to list all the Notes by Case Number. When you add to the Note it will show as a new entry with date time and entered by information. Long notes can be split into multi-line notes to prevent large records.


    .
    ~

    Bill

  3. #3
    Join Date
    Sep 2004
    Location
    Kuala Lumpur
    Posts
    60
    I have a pet hamster Donkey_Pet.

    LOL

  4. #4
    Join Date
    Sep 2004
    Location
    Tampa, FL
    Posts
    520
    Thanks Bill.

    The code is much more elegant than my current solution of using the text box and a button that runs an update query. Keep trying to use more VB in my DB's

    Thanks
    Darasen

Posting Permissions

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