messagebox text reverse

3 posts, 1 answers
  1. Behin
    Behin avatar
    12 posts
    Member since:
    Oct 2012

    Posted 03 Oct 2012 Link to this post

    hello
    I use messagebox and set the Rtl=Yes,the text message language is in persian or arabic,then
    I want to change the font of messagebox  so I use html in message text
    (RadMessageBox.Show(this, "<html><font=Tahoma>سلام دوست من</html>", "title",
                MessageBoxButtons.OK, RadMessageIcon.Info, MessageBoxDefaultButton.Button1, RightToLeft.Yes);)
    but when the messagebox is showDialog the Text is  displayed in reverse.
    for example i write "سلام دوست من" in textmessage but its shown "من دوست سلام" .
    please help me to solve this problem.

  2. Answer
    Ivan Todorov
    Admin
    Ivan Todorov avatar
    688 posts

    Posted 05 Oct 2012 Link to this post

    Hello Behin,

    Thank you for contacting us.

    Currently, our HTML-like text rendering engine does not support right-to-left languages. However, if you need to change the font of the entire text, then you can set the Font property of the message box label. The following code snippet demonstrates this:
    private void ShowMessageBox()
    {
        RadMessageBox.Instance.Controls["radLabel1"].Font = new Font("Tahoma", 12f, FontStyle.Regular);
        RadMessageBox.Show("This is Tahoma", "Message Box");
    }

    I hope this will help you. Do not hesitate to ask if you have any additional questions.

    Greetings,
    Ivan Todorov
    the Telerik team
    RadControls for WinForms Q2'12 release is now live! Check out what's new or download a free trial >>
  3. UI for WinForms is Visual Studio 2017 Ready
  4. Behin
    Behin avatar
    12 posts
    Member since:
    Oct 2012

    Posted 06 Oct 2012 Link to this post

    Thank you very much,It was the answer.
Back to Top