473,785 Members | 2,218 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

images in arrays..

How i can store images in array @ runtime..? What are the possbile ways..

Thankz..
-
Mähésh Kumär. R

Nov 17 '05 #1
6 10798

ArrayList myImages = new ArrayList();
myImages.Add ( image1 );
myImages.Add ( image2 );
myImages.Add ( image3 );

// where image# is an image object variable
"Maheshkuma r.R" <cy**********@y ahoo.com> wrote in message news:uW******** ******@TK2MSFTN GP12.phx.gbl...
How i can store images in array @ runtime..? What are the possbile ways..

Thankz..
-
Mähésh Kumär. R

Nov 17 '05 #2

ArrayList myImages = new ArrayList();
myImages.Add ( image1 );
myImages.Add ( image2 );
myImages.Add ( image3 );

// where image# is an image object variable
"Maheshkuma r.R" <cy**********@y ahoo.com> wrote in message news:uW******** ******@TK2MSFTN GP12.phx.gbl...
How i can store images in array @ runtime..? What are the possbile ways..

Thankz..
-
Mähésh Kumär. R

Nov 17 '05 #3
Thnkz Bass, again i struck in adding images to listview controls,

........functio n (string[] fname)

{

mycontrol.filen ame = fname[i].ToString(); // image filename assigned to my control

a = mycontrol.copyI mage2Clipboard; // and also taking first frame of that image for thumbnail generation

Bitmap bmp= new Bitmap(Clipboar d.GetImage());

listView2.Items .Add(fname[i]); // Here i'm adding filenames to the list control, but i want to add image to the list control..how can i do this ..please guide

...

..

..}

..

How can i add an image to the list view control in this scenario..?

Maheshkumar.R

"Dan Bass" <Not Listed> wrote in message news:uK******** ******@TK2MSFTN GP12.phx.gbl...

ArrayList myImages = new ArrayList();
myImages.Add ( image1 );
myImages.Add ( image2 );
myImages.Add ( image3 );

// where image# is an image object variable
"Maheshkuma r.R" <cy**********@y ahoo.com> wrote in message news:uW******** ******@TK2MSFTN GP12.phx.gbl...
How i can store images in array @ runtime..? What are the possbile ways..

Thankz..
-
Mähésh Kumär. R

Nov 17 '05 #4
Thnkz Bass, again i struck in adding images to listview controls,

........functio n (string[] fname)

{

mycontrol.filen ame = fname[i].ToString(); // image filename assigned to my control

a = mycontrol.copyI mage2Clipboard; // and also taking first frame of that image for thumbnail generation

Bitmap bmp= new Bitmap(Clipboar d.GetImage());

listView2.Items .Add(fname[i]); // Here i'm adding filenames to the list control, but i want to add image to the list control..how can i do this ..please guide

...

..

..}

..

How can i add an image to the list view control in this scenario..?

Maheshkumar.R

"Dan Bass" <Not Listed> wrote in message news:uK******** ******@TK2MSFTN GP12.phx.gbl...

ArrayList myImages = new ArrayList();
myImages.Add ( image1 );
myImages.Add ( image2 );
myImages.Add ( image3 );

// where image# is an image object variable
"Maheshkuma r.R" <cy**********@y ahoo.com> wrote in message news:uW******** ******@TK2MSFTN GP12.phx.gbl...
How i can store images in array @ runtime..? What are the possbile ways..

Thankz..
-
Mähésh Kumär. R

Nov 17 '05 #5

"Maheshkuma r.R" <cy**********@y ahoo.com> wrote in message news:%2******** ********@TK2MSF TNGP10.phx.gbl. ..
Thnkz Bass, again i struck in adding images to listview controls,

.......function (string[] fname)

{

mycontrol.filen ame = fname[i].ToString(); // image filename assigned to my control

a = mycontrol.copyI mage2Clipboard; // and also taking first frame of that image for thumbnail generation

Bitmap bmp= new Bitmap(Clipboar d.GetImage());

listView2.Items .Add(fname[i]); // Here i'm adding filenames to the list control, but i want to add image to the list control..how can i do this ..please guide

Make a class which will map bitmap with its name, and override ToString() method:

listView2.Items .Add(new BitmapNameMap(b mp, fname[i]));

////

class BitmapNameMap {

public BitmapNameMap(B itmap bmp, string name) {

m_bmp = bmp;m_mane = name;

}

public override ToString() { return m_name; }

public Bitmap Bitmap {

get { return m_bmp; }

}

}

Nov 17 '05 #6

"Maheshkuma r.R" <cy**********@y ahoo.com> wrote in message news:%2******** ********@TK2MSF TNGP10.phx.gbl. ..
Thnkz Bass, again i struck in adding images to listview controls,

.......function (string[] fname)

{

mycontrol.filen ame = fname[i].ToString(); // image filename assigned to my control

a = mycontrol.copyI mage2Clipboard; // and also taking first frame of that image for thumbnail generation

Bitmap bmp= new Bitmap(Clipboar d.GetImage());

listView2.Items .Add(fname[i]); // Here i'm adding filenames to the list control, but i want to add image to the list control..how can i do this ..please guide

Make a class which will map bitmap with its name, and override ToString() method:

listView2.Items .Add(new BitmapNameMap(b mp, fname[i]));

////

class BitmapNameMap {

public BitmapNameMap(B itmap bmp, string name) {

m_bmp = bmp;m_mane = name;

}

public override ToString() { return m_name; }

public Bitmap Bitmap {

get { return m_bmp; }

}

}

Nov 17 '05 #7

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

Similar topics

2
1670
by: Fabian | last post by:
This javascript is meant for learning language vocabulary, specifically colours on this example. However, when I use images in the mtWord array, it breaks when checking for correct answers. It works fine with text in those spaces. Direct links to the pages online: http://www.lajzar.co.uk/en/colours.html http://www.lajzar.co.uk/en/animals.html How can I fix this so the functions work with images in that array? It
4
1813
by: Stuart | last post by:
Hi there, I am trying to populate the array "yourImages" in the following code, http://www.javascriptkit.com/script/script2/preloadimage2.shtml except i am trying to fill it with the values from an access database. I already publish info from the database to an asp page, but i would like to preload the images. I open the database successfully like this ---------------
4
1701
by: seven | last post by:
This might be a newbie question or otherwise easy stuff for some of you, but it's tweaking me ... can't seem to get it to work right. I am working with a script that basically creates two arrays, and with a single call in the html, randomly inserts a graphic (which is linked to another page, as defined in the second array). The working example is http://seven.postmodern.com/insight/tarot/1cardreading.html What I would like to do is...
12
2535
by: Duderonomoy | last post by:
Hello, I am querying the JavaScript community to learn if others are having problems with Safari and JavaScript arrays: myImages = ; then referenced like this:
16
3501
by: Ian Davies | last post by:
Hello Needing help with a suitable solution. I have extracted records into a table under three columns 'category', 'comment' and share (the category column also holds the index no of the record in a hidden field) I wish the user to be able to edit the data in the table, so I have extracted the records into hiddenfield, textareas, dropdown list and checkbox so that they can make changes. I named these elements as arrays and wish to run an...
14
4200
lotus18
by: lotus18 | last post by:
Hello World I'm back again. LOL How to make an image arrays? I have 6 images named Button (Index from 1-6). I'm working on MouseMove events these images. So far I have these codes: Public Sub DefaultImage() It should be array For i = 1 To 6
2
993
by: rainclair | last post by:
Hello, I am trying to get 4 sets of thumbnails (each set in a hidden div tag) to onClick show in a main picture box. The links to the hidden divs are just below the main picture box. I can get everything to work, but my problem is when the next and previous are clicked ALL pictures are shown. What I would like is when the first set of thumbnails comes up, the big picture will only scroll through the first set of large pictures...etc... I...
1
2232
by: Stephen.Schoenberger | last post by:
I am working with some images as byte arrays and am not sure nor can I figure out if as I am reading the image and saving smaller sub- images I am reading across and down the image or down and back up or randomly? I need to know so in turn I can realize what the coordinates are of the sub-images. Here is a snippet of the code that is performing this task... for (int a = 1; a < 4800; a++) //will create 4800 sub images if a goes to...
1
2009
by: onyris | last post by:
Hi guys , I have got lost a bit with this flash i am doing at moment , i will try to explain the best i can and i'll post the code as well so u can see what i've done . I am using Action script 2, i have an XML with photos , at the moment are 7 photos in there. The code i have at the moment just simply reads from the xml all the photos adn display them in a movie clip . This is the code so far : step_sel_img.onRelease=function(){...
15
2501
Samishii23
by: Samishii23 | last post by:
First, images... I have a project that, at this time and version I am working with, I have 648 main stay images, so to say, plus another 100 or so in side features. They are going to stored in a outside .dll. Though I can't figure out if I want to use the Resources feature with C# rather then the "Direct" calling if you will. I have, in many Learning projects in the past have just used the direct call "C:\\Image.jpg" with success, even...
0
9646
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, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9483
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
10157
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...
1
10096
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
8982
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...
1
7504
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 presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6742
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
5386
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...
3
2887
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.