TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
Islam Mohammed osama
NA
4
0
Simple question about button text property
Jan 12 2006 1:24 PM
Hi,I am trying to create a button and assign its text property programmaticaly and my code is stated below. But I am receiving an exception telling me: // An unhandled exception of type 'System.Runtime.InteropServices.ExternalException' occurred in system.windows.forms.dll Additional information: A generic error occurred in GDI+. // Here is some details about what I am trying to do: -I overloaded the constructor of the form to receive a struct array(I) each containing a string array(Info) -I intend of making more than one button,one for each element of the struct array with its text property assigned to the fifth string after I clear this of course. -I tried the debug mode,the exception is thrown after the full excecution of the code,right after the application.run -Here is my code in the overloaded constructor of the form, it is called by another button in a different form: b=new Button(); b.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((System.Byte)(178))); b.TabIndex=0; b.TabStop=true; b.Location = new System.Drawing.Point(104, 512); b.Size = new System.Drawing.Size(112, 40); string t=I[0].Info[5];//<--just a string t=t.ToLower(); b.Text=t; please reply soon,THANKS.
Reply
Answers (
1
)
How to redirect to a new page from a page receiving a HTTP Post
Nested Multi Column Weekly Planner Rreport in CR.Net