473,386 Members | 1,790 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,386 software developers and data experts.

Images in C#

I have an app in which i use a lot of images ( Bitmaps and Pngs).
Most of the time i make a good use out of imagelist control sometimes i
just drop images in the project rather than in image list (use Bitmap m =
new Bitmap(GetType(), "image.bmp"); syntax). (I will be cleaning it all up
when i find a way to skin the app).

Now the problem is that i would like to make it so the bitmaps are loaded
during runtime so i can change any image any time (sort of skinning but don
t want to go to far yet).

With image lists i cannot do that currently. i have to readd each image and
recompile the program same with dropping images in the project (using
"Embedded Resource").
Anyone have any ideas how i can do this?
Nov 17 '05 #1
2 1367

"Raj Chudasama" <ra*@asteriasgi.com> wrote in message
news:e7**************@TK2MSFTNGP09.phx.gbl...
I have an app in which i use a lot of images ( Bitmaps and Pngs).
Most of the time i make a good use out of imagelist control sometimes i
just drop images in the project rather than in image list (use Bitmap m =
new Bitmap(GetType(), "image.bmp"); syntax). (I will be cleaning it all
up when i find a way to skin the app).

Now the problem is that i would like to make it so the bitmaps are loaded
during runtime so i can change any image any time (sort of skinning but
don t want to go to far yet).

With image lists i cannot do that currently. i have to readd each image
and recompile the program same with dropping images in the project (using
"Embedded Resource").
Anyone have any ideas how i can do this?


Hrm, how about having an "images" folder in the project. Then just reading
the images in from there? Maybe have an ini file that contains the list of
file names to load or something? Then you can just pass the path to the
image to Bitmap's constructor.

HTH,
Mythran

Nov 17 '05 #2
Thanks Mythran

i will try that route out :)
"Mythran" <ki********@hotmail.comREMOVETRAIL> wrote in message
news:%2****************@TK2MSFTNGP12.phx.gbl...

"Raj Chudasama" <ra*@asteriasgi.com> wrote in message
news:e7**************@TK2MSFTNGP09.phx.gbl...
I have an app in which i use a lot of images ( Bitmaps and Pngs).
Most of the time i make a good use out of imagelist control sometimes i
just drop images in the project rather than in image list (use Bitmap m =
new Bitmap(GetType(), "image.bmp"); syntax). (I will be cleaning it all
up when i find a way to skin the app).

Now the problem is that i would like to make it so the bitmaps are loaded
during runtime so i can change any image any time (sort of skinning but
don t want to go to far yet).

With image lists i cannot do that currently. i have to readd each image
and recompile the program same with dropping images in the project (using
"Embedded Resource").
Anyone have any ideas how i can do this?


Hrm, how about having an "images" folder in the project. Then just
reading the images in from there? Maybe have an ini file that contains
the list of file names to load or something? Then you can just pass the
path to the image to Bitmap's constructor.

HTH,
Mythran

Nov 17 '05 #3

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

Similar topics

7
by: Wayne | last post by:
I have a script that uses filesystemobject that reads files from a given path, in my case images. It is running on a server that is 2000 adv svr w/ all current patches. The script prior to some...
3
by: Simon | last post by:
This problem has been driving me mad for months.... Seen a few posts on forums about it but no answers... No mention on MSDN etc. XP Pro SP1, VS.NET (c#) .Net framework 1.1, IIS 5.1. In a...
10
by: Neo Geshel | last post by:
I am seeking to hand-roll my own blog in ASP.NET 2.0 and SQLExpress 2005. Why? Because I can. Because I will gain experience. The one thing that has me stumped at square one is inline images....
6
by: wattanabi | last post by:
Greetings, I'm attempting to layout a bunch of images in a grid using DIV's instead of a table. I currently have a 3x6 table that I need to convert to css. I've seen various example of a 3 to 4...
2
by: mouseit101 | last post by:
Hi, I'm writing a script that would (hopefully) search google images for whatever, and then return a list of URLs for the image. Right now I have: $dom = new DomDocument(); $url =...
0
by: Frenchie | last post by:
Hi, I have created a very neet menu from an example found on the MSDN library at: http://msdn2.microsoft.com/en-us/library/system.web.ui.webcontrols.menuitembinding.imageurlfield.aspx My...
1
by: Cerebral Believer | last post by:
Hi folks, I am using the following code for mouse over (roll-overs) in my XHTML code. <a onmouseover="document.getElementById('sitemap').src = '../images/buttons/sitemap_mo.jpg';"...
4
toxicpaint
by: toxicpaint | last post by:
Hi, can anyone give me a hand. I'm currently displaying 4 random images at the top of a page. I did this using an array of 35 pictures and then writing them to page. The problem I have is that in...
5
by: remon87 | last post by:
I need some help. I have javasript that creates the submenu but it works if I have a text with css. I need it to do the same with a roll over images. so when I click on the image the submenu...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
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: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
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
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
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
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...

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.