473,394 Members | 1,752 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,394 software developers and data experts.

Setting Textbox to Bold

I am trying to set the text in a textbox to Bold but I keep getting an error
that 'Bold" is ReadOnly? My code is as follows:

Dim N As New Form1()

If CheckBox1.Checked = True Then

N.TextBox1.Font.Bold = True

End If
--
------------------------------------
Wayne Wengert
wa***@wengert.org
Jul 19 '05 #1
1 2529
Jem
The Font object is immutable, i.e. you cannot change it's properties
individually. You can however create a new Font object that is the same in
all other respects as the existing one and assign it to the Font property.
If you keep switching between the two, you may wish to cache the two
objects.

Jem

"Wayne Wengert" <wa***@wengert.org> wrote in message
news:O3**************@TK2MSFTNGP11.phx.gbl...
I am trying to set the text in a textbox to Bold but I keep getting an error that 'Bold" is ReadOnly? My code is as follows:

Dim N As New Form1()

If CheckBox1.Checked = True Then

N.TextBox1.Font.Bold = True

End If
--
------------------------------------
Wayne Wengert
wa***@wengert.org

Jul 19 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Jose Gonzalez | last post by:
How to apply a numeric format to a textbox using xhtml? I know you have to use the "-wap-input-format" style tag in css. I can get this to work in a regular xhtml page, however, I've been...
1
by: Wayne Wengert | last post by:
I am trying to set the text in a textbox to Bold but I keep getting an error that 'Bold" is ReadOnly? My code is as follows: Dim N As New Form1() If CheckBox1.Checked = True Then ...
8
by: Jude | last post by:
Hi all, I'm trying to mix bold and non-bold text within a textbox on a report. Has anyone out there ever figured out how? Thanks! Jude
0
by: Reena | last post by:
Hi, Working with ASP.NET 2.0 with Masterpages. Here is my datagrid... <asp:DataGrid ID="dgSelectedFields" runat="server" BorderStyle=None GridLines="None" CssClass="grdData"
0
by: Jacob Donajkowski | last post by:
Once the user logs in I want to have the users switch from the Roster View to the Profile View and enter their profile infomation and save it. Then the next time they login and go to the Profile...
0
by: sjickells | last post by:
Hi I am having a problem using asp:TextBox's in a transparent table. I have a background image on the page and a table in the middle of the page. I have set the background colour of the table...
1
by: preeti13 | last post by:
hey i am trying to put the textbox column inside the datagrid but i don't have any idea how to do that please any one help me with this my code is like this: <asp:datagrid id="garidreason"...
3
by: zacks | last post by:
I have a multiline textbox control where I would like to load up with something like the following: This is Line 1 <- this line is NOT bold This is Line 2 <- this line is...
0
KalariaNitya
by: KalariaNitya | last post by:
Hello, could anybody help me? i have gridview, inside gridview i have one Update button & textbox update button update the quantity entered in textbox. i want to update the quantity on textbox on...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.