3 Replies Latest reply on Jun 30, 2018 7:23 AM by Rob Edwards

    Multiple Lines in a Message Box?

    Keaton Warn

      I have a message box that requires several long lines. Here is the example - it's all one line in the code though. As you can see, it's rather long for just one line.

       

      MsgBox ("This drawing does not appear to have a revision letter. Make sure the Revision Block is properly updated and that the correct revision letter is in the Revision custom property field. After the revision letter has been corrected, please try again.") & vbNewLine & vbNewLine & ("Remember, sometimes the Revision custom property link is disturbed by manual input and must have the current revision letter manually entered before it automatically updates with the revision block again." & vbNewLine & vbNewLine & "Check the PDF folder for this file name without a revision letter.")

       

       

      Is there an easy way in VBA to wrap a long text string into multiple lines in the code so I don't have to scroll so far to the right to modify it?

        • Re: Multiple Lines in a Message Box?
          Jason Kerns

          MsgBox ("This drawing does not appear to have a revision letter. " & _

          "Make sure the Revision Block is properly updated and that the " & _

          "correct revision letter is in the Revision custom property field. " & _

          "After the revision letter has been corrected, please try again.") & _

          vbNewLine & vbNewLine & ("Remember, sometimes the Revision custom " & _

          "property link is disturbed by manual input and must have the current " & _

          "revision letter manually entered before it automatically updates with " & _

          "the revision block again." & vbNewLine & vbNewLine & "Check the PDF folder for this file name without a revision letter.")

           

          Best way to copy and paste into notepad and remove the spaces then copy it and paste into vba.