Можно ли центрировать текст в msgbox? - PullRequest
0 голосов
/ 21 августа 2009

возможно ли центрировать текст в msgbox на vb.net? (аналогично

в html)

это не центрируется само по себе:

MsgBox("Thank you for using Eyes At Ease" & Chr(153) & vbCrLf & _
               "You can always access this screen by clicking on the icon in your taskbar" & vbCrLf & _
               "To adjust the Hue and Saturation of the screen, please drag the bars" & vbCrLf & _
               "You can also choose any color by clicking on CHOOSE and selecting a color" & vbCrLf & _
               "If you like the color you are currently use it and want to save it, you can click on ADD COLOR" & vbCrLf & _
               "The program will automatically start with the last colored you used", , "Eyes At Ease")

он также не центрируется без разрывов строки:

MsgBox("Thank you for using Eyes At Ease" & Chr(153) & _
               "You can always access this screen by clicking on the icon in your taskbar" & _
               "To adjust the Hue and Saturation of the screen, please drag the bars" & _
               "You can also choose any color by clicking on CHOOSE and selecting a color" & _
               "If you like the color you are currently use it and want to save it, you can click on ADD COLOR" & _
               "The program will automatically start with the last colored you used", , "Eyes At Ease")

Ответы [ 2 ]

2 голосов
/ 21 августа 2009

Нет, вы не можете.

Лучшее, что вы можете сделать, - это свернуть собственную форму MessageBox или подделать ее с пробелами.

2 голосов
/ 21 августа 2009

Вам нужно будет создать собственную форму, похожую на окно сообщения, в котором вы можете отцентрировать текст, а затем открыть его из пользовательской функции (которую затем можно вызвать почти так же, как с помощью MsgBox)

Добро пожаловать на сайт PullRequest, где вы можете задавать вопросы и получать ответы от других членов сообщества.
...