473,834 Members | 1,761 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

UserControl with a ComboBox

Moin!

I've 'composed' a special UserControl I need for my current project. On
this Control I put a ComboBox. The user is not allowed to access the
ComboBox directly (to protect some properties), so I used Properties to
enable the user to do some things in design mode. It all works fine
except for the Items property:

public ComboBox.Object Collection Items
{
get { return sicherungCombo. Items; }
}

I can't edit the items in design mode. I once read, that you need to add
an attribute, but I can't find it (not even the text I read).

Has anyone an idea how to do it? Oh, BTW: I (have to) use .net 1.1.

*** Sent via Developersdex http://www.developersdex.com ***
Mar 3 '06 #1
1 2156
Apply the DesignerSeriali zationVisibilit y attribute with a value of
DesignerSeriali zationVisibilit y.Content to allow the contents of the
collection to be persisted.

--
Tim Wilson
..NET Compact Framework MVP

"Jochen Berger" <be*****@web.de > wrote in message
news:OY******** ******@TK2MSFTN GP15.phx.gbl...
Moin!

I've 'composed' a special UserControl I need for my current project. On
this Control I put a ComboBox. The user is not allowed to access the
ComboBox directly (to protect some properties), so I used Properties to
enable the user to do some things in design mode. It all works fine
except for the Items property:

public ComboBox.Object Collection Items
{
get { return sicherungCombo. Items; }
}

I can't edit the items in design mode. I once read, that you need to add
an attribute, but I can't find it (not even the text I read).

Has anyone an idea how to do it? Oh, BTW: I (have to) use .net 1.1.

*** Sent via Developersdex http://www.developersdex.com ***

Mar 3 '06 #2

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

Similar topics

5
1464
by: codymanix | last post by:
My problem is: I have comboboxes which resides in a usercontrol. Always when the usercontrol changes its visible status (the dialog is shown or you switch to the tabpage where the usercontrol is), all text is selected in the textfield of the combobox. Is this a Bug? If yes, is there a workaround? -- cody
1
3701
by: bob scola | last post by:
I have a csharp, VS 2003 solution for a winform application The application uses an object called a "matter" and the class is defined in matter.cs. I can load matter objects into a combobox Matter matters= v.Matters; comboBox1.Items.AddRange(matters);
2
2102
by: John B | last post by:
Hello I want to create a set of controls that have some common methods and properties. I was thinking that I should subclass the UserControl class and add these common features there and then base all my custom controls on this new MyUserControl Class. Is this the way to go? The MyUserControl would not actually have any UI component and should be abstract I think. Does this mena that I should not create the control by just selecting...
13
5351
by: Michael Maes | last post by:
Hi, I have a UserControl containing some controls of which one is a ComboBox. All the InternalControls are Private and some are allowed to be accessed through Public Methods. One of the things I would like to do (of course) is set the DataBindings. Something clearly is wrong with the approach I use, because I can't set the Properties in the Designer, the DataSource-Property appears like 'ReadOnly', there is no "dropdown" with the list from...
8
4149
by: ChrisK | last post by:
Hi, I'm beginner with VB.net and i have a trouble... At work, they decided to program with tabcontrol...and i'mm in charge of this ! There is my problem. I've a form with one tabcontrol (TBC1 ). This TBC1 contents n TabPages ( TBP1,2,3,..,n) For each TBPn i 've got an specific usercontrol which have controls and code ( data access, ... ).
9
15366
by: davidr | last post by:
Hi, I've researched this a lot and have a well understanding but still can't get the darn textbox in the javascript. I have a textbox that is set to runat="server" and I have a client function for a comboBox when selectitemindexchanged happens it will trigger. I know it goes into that because I did a alert("test"). Now in there I want to take the item in the comboBox and put it in the textbox that is runat="server". I know I have...
5
19714
by: Blue | last post by:
We have a custom word processing type editor built with C# and .NET 2.0 and we need to support typing in languages other than English. I want to be able to use the Windows IME to enter in text similar to how it works in a text box. For example, if I put focus on a TextBox and then switch my language on the language bar to Japanese or Chinese, several buttons appear on the language bar including Input Mode, Input Style, Conversion Mode,...
3
2042
by: Martin | last post by:
Hi ! I've developed a small UserControl with five textbox and label. However, when I want to display the UserControl in a form, controls appear slowly one after one. I've activated double buffering and removed all code in the OnLoad, constructor and I still have the same problem. Here is the code that I use to display the UserControl un the form _objContainer.SuspendLayout();
4
2473
by: Martin | last post by:
Hi everyone ! For those who haven't read my previous post, I have a problem with a UserControl. When I try to display it on a form, controls seem to appear one after one. In the following example, it's less visible because controls don't execute any code... Is someone has an idea of how I could solve this problem and also improve the method ShowUserControl. I try to figure out I could flicker effect when I press the button twice quickly.
0
9797
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
9644
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
10793
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...
1
10547
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
9331
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
5626
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
5793
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4427
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
3977
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

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.