473,405 Members | 2,141 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,405 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 2530
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: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
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: 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
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
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
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

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.