Assigning Icons to Forms

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

As always, I am asking a stupid question

1) Creating a Direct3D graphic program

2) Create my Direct3D scree

3) I want that screen to have an icon (note that I create form through code)

4) Me.Text="Title of my screen" : ' Works

4) Me.Icon ???? What would be the command here

Thank you
 
* "=?Utf-8?B?VGVyaXNoRA==?= said:
As always, I am asking a stupid question.

1) Creating a Direct3D graphic program.

2) Create my Direct3D screen

3) I want that screen to have an icon (note that I create form through code).

4) Me.Text="Title of my screen" : ' Works

4) Me.Icon ???? What would be the command here?

Why not set the icon at design time?
 
There is no design time. It is all done through code

Let me also state that I HAVE looked at the examples, and NONE of the examples create an icon for the window either

Of course, your response totally evades the question. Say that I want the user to be able to change the icon of a form by loading in one of his own. How would this be done in code

I would have thought it to b

Me.Icon = ctype(fromfile("drive:\path\filename"), system.drawing.icon

but this does not work
 
Within the form, I just tried changing the form icon by writing one line in
C# and it works fine. so i am not sure what you are after... both of the
following statements work perfectly fine for me !!

this.Icon = System.Drawing.SystemIcons.Asterisk
this.Icon = new Icon("c:\\ba.ico");

TerishD said:
There is no design time. It is all done through code.

Let me also state that I HAVE looked at the examples, and NONE of the
examples create an icon for the window either.
Of course, your response totally evades the question. Say that I want the
user to be able to change the icon of a form by loading in one of his own.
How would this be done in code?
 
To: Saurab

Thank you, thank you, thank you, and THANK YOU

I knew it would be something simple. Thank you
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top