473,473 Members | 2,163 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

Can I do dynamic GUI components like in Java?

One thing I encountered a problem with when porting some Java code to C# is
that some GUIs in Java all the widgets are basicaly evolved from one class
and it gives you some strange flexibility like adding any component to other
components. Like having a JList you can add ListItems but they can be
anything from combo boxes to labels to even stuff like tables. Is it possible
to do something like this in C#? How do I handle this?
Aug 21 '06 #1
1 1849
"MrNobody" <Mr******@discussions.microsoft.comwrote in message
news:38**********************************@microsof t.com...
One thing I encountered a problem with when porting some Java code to C#
is
that some GUIs in Java all the widgets are basicaly evolved from one class
and it gives you some strange flexibility like adding any component to
other
components. Like having a JList you can add ListItems but they can be
anything from combo boxes to labels to even stuff like tables. Is it
possible
to do something like this in C#? How do I handle this?
You probably need to ask a much more specific question, and you probably you
need to spend some time learning how Windows Forms works. For a WinForms
application, the entire UI is built dynamically, creating controls at
runtime and gluing them together to form the UI - just take a look at the
"designer generated" code in YourForm.Designer.cs.

Since I don't know exactly what a JList is, I can't tell you exactly where
to look for the equivalent, but I'd guess that it's something like a
TableLayoutPanel in windows forms (but unless JList has a lot more
functionality than the name suggests, TLP probably does quite a lot more).

-cd
Aug 21 '06 #2

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

Similar topics

3
by: jonathan | last post by:
hey all, I'd like to implement an application that is truly dynamic: the components are not only just known at runtime, but also the components are unknown at runtime: ie: some don't even ship...
13
by: mr_burns | last post by:
hi, is it possible to change the contents of a combo box when the contents of another are changed. for example, if i had a combo box called garments containing shirts, trousers and hats, when...
7
by: Bil Muh | last post by:
Esteemede Developers, I would like to Thank All of You in advance for your sincere guidances. I am developing a software using Visual C++ .NET Standard Edition with Windows Form (.NET)...
4
by: jrefactors | last post by:
I want to distinguish between static SQL, dynamic SQL, and embedded SQL, but couldn't find too much useful resources in the web. For example, if we put SQL statements (SELECT, INSERT, UPDATE,...
4
by: Charlie | last post by:
I am trying to create dynamic content in a Windows Form using external data to determine UI elements. The code works fine at runtime. I have tried adding code in Sub New, after...
0
by: Pascal Costanza | last post by:
Dynamic Languages Day @ Vrije Universiteit Brussel ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Monday, February 13, 2006, VUB Campus Etterbeek The VUB (Programming Technology Lab,...
0
by: vidhyasreddy | last post by:
Hi All, While we are Localizing our product we faced below problem: java.awt components not able to display some non-english charecters like \u2019 , \u2018 , \u2026 , \u2013 , \u8230 . ...
5
by: Kursat | last post by:
Hi, I want to add new collapsable panel items using java script at client side. Is this possible to create Ajax components like collapsable panel without server round trip? Thanks in advance.
5
by: Guillermo Schwarz | last post by:
C++ers, I have programmed in C++ since 1991 and I probably created my best abstraction layers in C++ in those days. Since 2001 I've been programming in Java (at first against my will, then I...
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
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...
1
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...
0
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...
1
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...
0
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 ...
0
muto222
php
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.