+ Reply to Thread
Results 1 to 5 of 5

Text box with asterisk border on top and bottom?

  1. #1
    Valued Forum Contributor
    Join Date
    02-26-2010
    Location
    Chattanooga, TN
    MS-Off Ver
    Excel 2003/2007/2010/2016
    Posts
    432

    Talking Text box with asterisk border on top and bottom?

    Hello!

    I have a text box with a solid border, but now we are going to just an asterisks border on the top and bottom. So it should look like this:


    ***************
    text

    ***************

    Can this be done?

    VR/Lost
    Last edited by leaning; 12-16-2010 at 09:49 PM. Reason: Solved!

  2. #2
    Forum Expert teylyn's Avatar
    Join Date
    10-28-2008
    Location
    New Zealand
    MS-Off Ver
    Excel 365 Insider Fast
    Posts
    11,372

    Re: Text box with asterisk border on top and bottom?

    Why revert to ASCII style formatting in the age of GUI? Why make life more complicated than it needs to be?

  3. #3
    Valued Forum Contributor
    Join Date
    02-26-2010
    Location
    Chattanooga, TN
    MS-Off Ver
    Excel 2003/2007/2010/2016
    Posts
    432

    Re: Text box with asterisk border on top and bottom?

    Teylyn,

    We use it for military document signature blocks like this:

    ****************************
    JOHN J. SMITH
    LCDR, USN
    COMMANDING OFFICER
    *****************************

    I fully agree with you that the construct is archaic, but since that is what the original US government regulation (probably from the 1960's) has in it, that is what we do.

    Right now, the text box I have has a single line border, but then I was "informed" that that didn't match the regulation verbatim (which has the asterisks top and bottom). IN Excel, there is an option for the border to be be dotted on all 4 sides, but not one for only 2 sides (that I can see).

    So, I figured VBA to format the textbox would be the way to go.

    HTH!

    VR/Lost

  4. #4
    Valued Forum Contributor
    Join Date
    02-26-2010
    Location
    Chattanooga, TN
    MS-Off Ver
    Excel 2003/2007/2010/2016
    Posts
    432

    Re: Text box with asterisk border on top and bottom?

    Teylen.

    I came up with this which works and looks OK:

    In the formula bar for the text box, type:
    ="****************************"&CHAR(10)&"JOHN J. SMITH"&CHAR(10)&"LCDR, USN"&CHAR(10)&"COMMANDING OFFICER"&CHAR(10)&"****************************"

    So, no VBA solution needed.

    Thanks!

    VR/Lost

  5. #5
    Forum Moderator davesexcel's Avatar
    Join Date
    02-19-2006
    Location
    Regina
    MS-Off Ver
    MS 365
    Posts
    13,480

    Re: Text box with asterisk border on top and bottom?

    Hi,
    You could set up the text in the textbox with the asterisks then format the textbox borders to no color, so it will appear that the asterisks are the border

    ALt +enter also gives you a new line in a cell
    Last edited by davesexcel; 12-14-2010 at 07:26 AM.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1