Text box question

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • dkotula
    New Member
    • Feb 2009
    • 20

    Text box question

    Hello,

    Is there a way that whenever a certain symbol appears, to strip the symbol and have the line following the symbol move down to the next line in my text box.

    Even if I can get the line to move down without removing the symbol would be fine.
    I cannot paste the symbol on here, but it is a question mark inside a box. The symbol is coming from a Progress database I'm linking my tables to.

    This is a textbox on a form, no need to save it to a table.

    Thank you
    Dave
  • missinglinq
    Recognized Expert Specialist
    • Nov 2006
    • 3533

    #2
    Since you can't even paste the symblem here, this is going to be problematical!

    What Font is this symbol part of? Could you not use Windows Character Map (Programs - Accessories - System Tools) to find the symbol then copy it and paste it into the code window? If you can you can try this:

    [TextBoxName] = Replace([TextBoxName], "@", vbNewLine)

    replacing the ampersand (@) with your symbol. Where you'd do this depends on exactly what you're doing with the data. I suppose you could do a calculated field in a query, which would be have the syntax:

    ParsedText:Repl ace([TextBoxName], "@", vbNewLine)

    Then, in forms/reports use the ParsedText field instead of the imported field.

    Linq ;0)>

    Comment

    • dkotula
      New Member
      • Feb 2009
      • 20

      #3
      Thank you for the code above.

      Strange, but if I copy the complete line from access, and paste it into word, the ? mark is gone and recognizing it as a new line. My guess is that access is placing the question mark in the fields. Do I need to change the properties for the textbox to allow additional lines in my form?

      Comment

      • dkotula
        New Member
        • Feb 2009
        • 20

        #4
        Same thing when I paste here. See below:


        VALVE STEM 316L - 1/4"
        MATERIAL: SA479-316L
        FINISH: < 15 MICROINCHES RA ON ALL SURFACES

        Font in word shows up as Calibri (Body)

        Comment

        • dkotula
          New Member
          • Feb 2009
          • 20

          #5
          Wow, changed the font to Txt and it works correctly.

          Dave :)

          Comment

          • dkotula
            New Member
            • Feb 2009
            • 20

            #6
            Nope, spoke too soon, just replaced it by a vertical line

            Comment

            • dkotula
              New Member
              • Feb 2009
              • 20

              #7
              See attached screen shot.
              Attached Files

              Comment

              • dkotula
                New Member
                • Feb 2009
                • 20

                #8
                I'm finding that this is a line break issue, and have set the following:
                Can Grow
                Enter Key Behavior = New Line in Field

                This has not changed anything.
                It appears to me that the text box properties need to be changed to allow line breaks, or whatever indicates a linebreak from the source is incompatable.

                If the data is pasted to other office programs, it seems to work correctly, although I cannot paste it to Notepad.

                How can I get the text box to be compatable with the type of text displayed?

                Thank you
                Dave

                Comment

                Working...