Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

Rich text box

Posted on 2002-07-05
3
Medium Priority
?
224 Views
Last Modified: 2010-05-02
Can a user enter text in two different fonts(essentially two different languages) in a single richtext box? The user will enter text which is a combination of two different fonts which will be stored in the database. If it is not possible to do it with rich text box, what other control can be used for the above problem. Thanks in advance.
0
Comment
Question by:mkarthikeyan
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 143

Accepted Solution

by:
Guy Hengel [angelIII / a3] earned 300 total points
ID: 7131689
Using the SelFontName and SelFontSize you can format the selected text the given FontName and Size.
CHeers
0
 
LVL 22

Expert Comment

by:Mohammed Nasman
ID: 7131768
Hello

Here's a sample to format text in RichTextBox
Private Sub Command1_Click()
  With RichTextBox1
    .Text = "Hello World"
    .SelStart = 0
    .SelLength = 5
    .SelFontName = "Tahoma"
    .SelFontSize = 20
    .SelStart = 6
    .SelLength = 11
    .SelFontName = "Times new roman"
    .SelFontSize = 18
    .SelItalic = True
  End With
End Sub

Best regards
0
 

Author Comment

by:mkarthikeyan
ID: 7133445
Thanks it worked out. But I am having problems when I retrieve it from the database and again show in the rich text box.
0

Featured Post

Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

If you have ever used Microsoft Word then you know that it has a good spell checker and it may have occurred to you that the ability to check spelling might be a nice piece of functionality to add to certain applications of yours. Well the code that…
Most everyone who has done any programming in VB6 knows that you can do something in code like Debug.Print MyVar and that when the program runs from the IDE, the value of MyVar will be displayed in the Immediate Window. Less well known is Debug.Asse…
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…
Suggested Courses

610 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question