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

Populating Enum's dynamically

Hi,

I want to populate my Enum dynamically from the database. Is that possible?
If so, what is the approach that I need to take.

I need this because I have some set of constants in my table which I want to
fetch once the moment i start my application and store that in Enum.

Regards
Sudhakara.T.P.
Nov 21 '05 #1
1 1578
"Sudhakara.T.P." <Su*********@discussions.microsoft.com> schrieb:
I want to populate my Enum dynamically from the database. Is that
possible?


Nope, that's not supported.

--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://classicvb.org/petition/>

Nov 21 '05 #2

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

Similar topics

3
by: Pjotr Wedersteers | last post by:
Hi I am not even sure if it is at all possible, and I can't find the stuff I am looking for, probably using the wrong search keys. WAMP machine (XP, 2.50.2, 4.1.5, 5.0.2) I have a field in...
5
by: Moe Green | last post by:
I want create a method which uses a dynamically enum as the type of one of its parameters. I can create the assembly with this code: AssemblyName myAssemblyName = new AssemblyName();...
4
by: Popoxinhxan | last post by:
Hi guy, i just wondering that is it posible to convert the array of string to enum types dynamically, for example i get the list of countries name from database and would like to convert all of...
5
by: | last post by:
Trying to learn about manipulating collections of objects, and populating these objects dynamically from datasources. Could someone post a code sample that shows the following: Instantiating a...
2
by: Chowdary Doppalapudi | last post by:
Hi All Is there any way to create the Enum dynamically from database table. Thank Chowdary D
0
by: Duderino82 | last post by:
$sql = "SHOW COLUMNS FROM table LIKE 'subject' "; $qry = mysql_query($sql) or die("Query not valid: " . mysql_error()); $res = mysql_fetch_object($qry); // This returns a row with a field 'Type'...
4
by: Ryan Liu | last post by:
Can I create an enum dynamically in the code, e.g. data base driven? Thanks! Ryan
4
by: Steve Teeples | last post by:
Given this definition of an enum: enum MyEnum { d1=1, d2=2 } Is there a way to dynamically create this same enum at runtime? I want to
1
by: NvrBst | last post by:
I have a dropdown list, then right now I simply call BGColorComboBox.DataSource = Enum.GetValues(typeof(KnownColor)); BGColorComboBox.SelectedItem = KnownColor.Black; Which works great except...
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: 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$) { } ...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
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
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.