473,915 Members | 5,904 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

form's icon

Vic
I am trying to change an icon associated with my application's main form and
the application itself.

1. I selected my main form in IDE "Solution" tab and went to "Properties "
window.
2. I found "Icon" property, browsed for and selected a new icon.
3. I noticed the icon changed on my form
4. Ran my application and sure thing, the new icon replaced the default .NET
icon.

Several days after that I created yet another icon. I followed the same
steps (see above) to use the new icon, but all in vain. I do see the icon on
the form change in design view, but when I run my app, there is still the
old icon displayed.

I noticed, this is how my icon is loaded (code generated by IDE): asdasd

this.Icon = ((System.Drawin g.Icon)(resourc es.GetObject("$ this.Icon")));

Looks like the icon is loaded from resources. Does it mean, that when I am
setting the new icon, my resources aren't updated? Is that a bug? Am I doing
something wrong?

Thanks for your help in advance.

Vic
Nov 15 '05 #1
2 9460
Hi,

I have also experienced problems with altering the program icon in with the
designer. I would recommend loading the icon manually and assigning it to
the Icon property just after the form has been created.

--
Dmitriy Lapshin [C# / .NET MVP]
X-Unity Test Studio
http://x-unity.miik.com.ua/teststudio.aspx
Bring the power of unit testing to VS .NET IDE

"Vic" <ro****@gat.com > wrote in message
news:%2******** ********@TK2MSF TNGP10.phx.gbl. ..
I am trying to change an icon associated with my application's main form and the application itself.

1. I selected my main form in IDE "Solution" tab and went to "Properties "
window.
2. I found "Icon" property, browsed for and selected a new icon.
3. I noticed the icon changed on my form
4. Ran my application and sure thing, the new icon replaced the default ..NET icon.

Several days after that I created yet another icon. I followed the same
steps (see above) to use the new icon, but all in vain. I do see the icon on the form change in design view, but when I run my app, there is still the
old icon displayed.

I noticed, this is how my icon is loaded (code generated by IDE): asdasd

this.Icon = ((System.Drawin g.Icon)(resourc es.GetObject("$ this.Icon")));

Looks like the icon is loaded from resources. Does it mean, that when I am
setting the new icon, my resources aren't updated? Is that a bug? Am I doing something wrong?

Thanks for your help in advance.

Vic


Nov 15 '05 #2
Vic
Thanks, will do.

"Dmitriy Lapshin [C# / .NET MVP]" <x-****@no-spam-please.hotpop.c om> wrote
in message news:u1******** ******@TK2MSFTN GP12.phx.gbl...
Hi,

I have also experienced problems with altering the program icon in with the designer. I would recommend loading the icon manually and assigning it to
the Icon property just after the form has been created.

--
Dmitriy Lapshin [C# / .NET MVP]
X-Unity Test Studio
http://x-unity.miik.com.ua/teststudio.aspx
Bring the power of unit testing to VS .NET IDE

"Vic" <ro****@gat.com > wrote in message
news:%2******** ********@TK2MSF TNGP10.phx.gbl. ..
I am trying to change an icon associated with my application's main form and
the application itself.

1. I selected my main form in IDE "Solution" tab and went to "Properties " window.
2. I found "Icon" property, browsed for and selected a new icon.
3. I noticed the icon changed on my form
4. Ran my application and sure thing, the new icon replaced the default

.NET
icon.

Several days after that I created yet another icon. I followed the same
steps (see above) to use the new icon, but all in vain. I do see the icon on
the form change in design view, but when I run my app, there is still

the old icon displayed.

I noticed, this is how my icon is loaded (code generated by IDE): asdasd

this.Icon = ((System.Drawin g.Icon)(resourc es.GetObject("$ this.Icon")));

Looks like the icon is loaded from resources. Does it mean, that when I am setting the new icon, my resources aren't updated? Is that a bug? Am I

doing
something wrong?

Thanks for your help in advance.

Vic

Nov 15 '05 #3

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

Similar topics

0
1038
by: Microsoft | last post by:
How to make a sizable form with a title and a close button, but no icon and not ControlBox=false ??? Thank
3
5105
by: VJ | last post by:
I am trying to set my Form's Icon property at run time based on certain parameters. I have a imglist in the form for other purposes I would like to use the same image list to keep the Forms icon and set the icon. How do I get this done.. VJ
14
2156
by: Kishan Hathiwala | last post by:
Hi i have kept a statusbar in the form with panels = true. and total there 3 panels. whenever i click on the 3rd panel a menu appears showing online and offline and either is enable at a time. once i clic on online its icon changes to connecticon (assume its there) and whenever i click on offline, its icon changes to disconnection (assume this is also there). now the problem is i have kept one icon for connection (ie when its online -...
3
2859
by: Nina | last post by:
Hi there, I assigned icon for a window's form using form's Icon property at design time. Now I want to change the icon. I tried to replace the old icon with the new icon using form's Icon property. Somehow in the form's property window's Icon property has changed to new icon, but on the form it still uses the old icon. Then I tried to set Icon property to None, and it doesn't allow me to do it. I don't know why and how can I fix...
5
2375
by: Tom | last post by:
I have a main VB.NET application that loads another VB.NET DLL dynamically. Once I have done that, I would like to be able to 'get' the icon of a form in that dynamically loaded DLL. How would one go about doing this in the main form, once the DLL has been loaded? Thanks in advance. Tom --
4
6561
by: randy1200 | last post by:
I have a Windows application that previously had the company logo "MyCompany.ico" added to the upper left-most corner. The company has since issued a new version of "MyCompany.ico" that looks completely different. I overwrote the old ico file with the new ico file and re-ran the program. I still see the old logo at run-time. I right-clicked the project-> Add Existing Item-> added the new ico file. I set the build action to Embedded...
2
2598
by: Emby | last post by:
OK, really dumb question - how do I set the icon for a shortcut to a WinForms app? I've set an icon into the main form's Icon property, and its ShowIcon and ShowInTaskbar properties are set to True (the defaults). And when the form is displayed, the icon is seen in the upper left hand corner of the form. But when you create a shortcut for the app, it has the default "empty window" icon. If you try to change the shortcut's icon, that...
2
4418
by: Rainer Queck | last post by:
Hello NG, what are the right dimensions for a window icon, used on a mdi child window? My Problem: I used a third party Icon-Designer to design some icons for my application. Those icons look ok on a mdi child as long as it is not maximize. As soon as I maximize the window, the Icon is placed into the menu bar (I assum the is normal) but its size is aproximatly 3 times bigger.
4
5046
by: Marcolino | last post by:
Hi, I have simple needs but I don't know how to implement it. I have application that create Dynamic Button. I need to set the image on this button, getting the icon from a form. So pratically I need to convert dinamically a Form.Icon to Button.Image runtime, but i don't know how. Any help would be appreciated. Many Thanks
0
9883
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 effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
11359
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, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10928
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 tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
10543
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 protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
9734
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
7259
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5944
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
6149
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
3
3370
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.