473,406 Members | 2,273 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,406 software developers and data experts.

Problem with my component

Hi,
I have created a component similar to ImageList but my component stored Icons
(System.Drawing.Icon). For being precise, the stored data is an object created
from me that to its inside it has an istance of the Icon object.
The problem is that the icons store in the collection associated to my IconList
(IconList.Icons) at Design-Time, were removed a Run-time. Me meeting therefore
with one empty collection. How I can resolve the problem?

Sorry form my English :)

Mauro.
Nov 16 '05 #1
3 1051
Hi Mauro,

I don't know how to do it directly, but i show you a way.

An "ImageList" uses "ImageStream" property to serialize its
content to the resources. I think that you can do it similar to
ImageList. You will need the property that will serialize whole icon
collection to the resources.

You should add [Browsable(false)] to hide this property in property
explorer.

HTH

Marcin
Hi,
I have created a component similar to ImageList but my component stored
Icons (System.Drawing.Icon). For being precise, the stored data is an
object created from me that to its inside it has an istance of the Icon
object.
The problem is that the icons store in the collection associated to my
IconList (IconList.Icons) at Design-Time, were removed a Run-time. Me
meeting therefore with one empty collection. How I can resolve the
problem?

Sorry form my English :)

Mauro.

Nov 16 '05 #2
Marcin Grzebski ha detto questo mercoledì :
Hi Mauro,

I don't know how to do it directly, but i show you a way.

An "ImageList" uses "ImageStream" property to serialize its
content to the resources. I think that you can do it similar to ImageList.
You will need the property that will serialize whole icon collection to the
resources.

You should add [Browsable(false)] to hide this property in property
explorer.

HTH

Marcin


Hi Marcin,
thanks for your answer. I will try to make as you have suggested to
me. :-)

Mauro.

--
Questa è una firma automatica di MesNews.
Sito: http://mesnews.no-ip.com

Nov 16 '05 #3
Mauro ci ha detto :
Marcin Grzebski ha detto questo mercoledì :
Hi Mauro,

I don't know how to do it directly, but i show you a way.

An "ImageList" uses "ImageStream" property to serialize its
content to the resources. I think that you can do it similar to ImageList.
You will need the property that will serialize whole icon collection to the
resources.

You should add [Browsable(false)] to hide this property in property
explorer.

HTH

Marcin


Excuse me but I do not succeed to understand how creating the
IconListStreamer object.
1) I have created a IconListStreamer class that implements
ISerializable
2) I have created a IconStream property of IconListStreamer type in my
IconList class
3) I don't understand how serializzare the Icons' collection. :-(

Mauro

--
Questa è una firma automatica di MesNews.
Sito: http://mesnews.no-ip.com

Nov 16 '05 #4

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

Similar topics

6
by: Iain Bishop | last post by:
I'm trying to model objects for the following problem: A building site contains assemblies, each of which can contain other assemblies and/or materials. I have modelled this using a Site...
6
by: SeaPlusPlus | last post by:
I've got a problem... IE 6.0 twitches when I hover over a link then it won't twitch again for that group of links but will twitch the first time on the next group... and the next group... etc... ...
2
by: Peter Wright | last post by:
Hi all. Hopefully this should demonstrate the problem I'm having: http://flooble.net/~pete/focus-problem-demo/ (I'm testing it in Mozilla only, but I'm not sure if it's actually a...
1
by: Polo | last post by:
Hi, I have a Custom ExpandableTypeConverter (that show the property of a object readonly) Some properties of this sub object have the Browsable(false) attribute but in the PropertyGrid these...
14
by: Christian Kaiser | last post by:
We have a component that has no window. Well, no window in managed code - it uses a DLL which itself uses a window, and this is our problem! When the garbage collector runs and removes our...
2
by: Stefan | last post by:
Hi there! I'm very new to XML and XSLT, so while working i encountered the following, probably very easy to solve, problem. i've got 2 XML-files, which look like this: LinesOfCode.xml:...
1
by: ricolee99 | last post by:
Hi everyone, I have a .net application called "InteropService". InteropService consumes a com component called 'B'. 'B' consumes a third party dll. Everything seems to work fine. However,...
8
by: tcl | last post by:
I'm doing a research about 3DES in C programming and VHDL language. I would like to have the same output in both language but not successful. The source code for C language was found in the web:-...
1
by: luigi7up | last post by:
Hello to everyone... I'm having a little problem with displaying a number of products in my shoping cart that I'm writing from scratch. The structure of a site is following: INDEX.php is my main...
3
by: Stephen Torri | last post by:
Here is my attempt at implementing a object factory. The purpose of this is to replace a large switch statement in a factory class with the functors. I get an error at line 88, marked, "expected...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
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
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,...
0
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...

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.