Results 1 to 4 of 4
  1. #1
    Join Date
    Mar 2004
    Location
    Glasgow, Scotland
    Posts
    107

    Unanswered: Memo field in Report

    Hi,

    I am trying to add the value of two text boxes in a report to a single text box but I want to put a character retur between the first value and the second field e.g. Text Box Value =[txtJobDetails_FinishingToBeCut] & Chr(13) & [txtJobDetails_FinishingToBeDrilled].

    The problem is it doesn't recognize the Chr(13) code I'm using because it is a text box and not a memo field - is there a way to create an unbound memo field on a report. Setting the Grown and Shrink properties do not work as it's still as text field and doesn't recognize Chr(13).

    Please see the example I have attached.

    Cheers
    Matt
    Attached Files Attached Files

  2. #2
    Join Date
    Nov 2003
    Location
    Sussex, England
    Posts
    404

    Smile Carriage return and memo fields

    Try looking at the post:

    newLine in a memo field and print error


    A bit further down. It may help you.

  3. #3
    Join Date
    Mar 2004
    Location
    Glasgow, Scotland
    Posts
    107

    Solved!!

    The following code works in the datasource of the text box:=[txtJobDetails_FinishingToBeCut] & Chr(13) & Chr(10) & [txtJobDetails_FinishingToBeDrilled]

    U obviously need to add both a Chr(13) and a Chr(10)....

  4. #4
    Join Date
    Dec 2003
    Location
    Dallas, TX
    Posts
    1,004
    Hi mmcdonald

    Here is a simple solution you can try is what I just did. Can be done for both the Form or the Report. Take the TextBox you are wanting the concatenated fields to be held in and do this:

    Lets say you have FName field and LName field and want the results in the CombinedText txtbox. In the Combined TextBox field in DesignView, go to the FormatTab and set CanShrink/CanGrow to YES.
    Next, go to the DataTab in click on the ControlSource box and open it up.
    Then, type this in it:
    Code:
          =[FName] & "
    " & [LName]
    And that's it. In case it doesnt show well on here or you can't tell, All I did was type in the (=) sign, DoubleClick on the FName field to input it there......
    THEN HOLD YOUR Ctrl KEY DOWN AND HIT ENTER That's the trick, and then DoubleClick on the LName field to input it there also. Of course you are aware of the Concatenate characters. Notice what follows directly Behind the FName field ( &" ) and what Preceeds the LName field ( "& ) . Give it a try and see what you get. I just did it myself and it worked fine. From that point on whatever you type in both the FName and LName fields will come into the report...and you don't have to worry about hitting enter or carriage return, it's all automatic.

    Have a great day
    Bud

Posting Permissions

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