Click here to Skip to main content
16,005,467 members
Home / Discussions / ASP.NET
   

ASP.NET

 
GeneralInfo req for UIPAB & EWorldUI Calendar Control Pin
vamsimohan2121-May-08 1:28
vamsimohan2121-May-08 1:28 
GeneralRe: Info req for UIPAB & EWorldUI Calendar Control Pin
eyeseetee21-May-08 2:22
eyeseetee21-May-08 2:22 
Questionhow to get selected value from dynamically created dropdownlistbox which is placed in placeholder Pin
vidhyap21-May-08 1:17
vidhyap21-May-08 1:17 
AnswerRe: how to get selected value from dynamically created dropdownlistbox which is placed in placeholder Pin
Christian Graus21-May-08 1:18
protectorChristian Graus21-May-08 1:18 
GeneralRe: how to get selected value from dynamically created dropdownlistbox which is placed in placeholder Pin
vidhyap21-May-08 1:50
vidhyap21-May-08 1:50 
GeneralRe: how to get selected value from dynamically created dropdownlistbox which is placed in placeholder [modified] Pin
Sandeep Akhare21-May-08 3:01
Sandeep Akhare21-May-08 3:01 
GeneralRe: how to get selected value from dynamically created dropdownlistbox which is placed in placeholder Pin
vidhyap21-May-08 17:12
vidhyap21-May-08 17:12 
GeneralRe: how to get selected value from dynamically created dropdownlistbox which is placed in placeholder Pin
vidhyap21-May-08 19:06
vidhyap21-May-08 19:06 
Hi Sandeep,

I tried to work out on what u said.but i have not worked on request object and all.

and i am attaching the code which will create the dropdown list dynamically.please let me now how can I access the selected value of this dropdownlist when I click on button.

please help me to resolve this issue.

below is the code to create dropdownlist dynamically.

protected void createddl(int surveyID, int attributeID)
   {
       ISession session = NHibernateSessionManager.Instance.GetSession();
       IQuery attributeValueQry = session.CreateQuery("from MasterValueEntity mve where TypeID='" + attributeID + "'");
       IList attributeValueList = attributeValueQry.List();
       IQuery labelValueQry = session.CreateQuery("from MASTERTYPEEntity mte where TypeID='" + attributeID + "'");
       IList labelValueList = labelValueQry.List();
       IQuery hierarchyValueQry = session.CreateQuery("from HierarchyEntity");
       IList hierarchyValueList = hierarchyValueQry.List();
       DropDownList list = new DropDownList();
       list.Items.Add("Select");
       Label label1 = new Label();
       if (attributeID == 0)
       {
           label1.Text = "Hierarchy";
           label1.Width = Unit.Percentage(60);
           label1.Height = Unit.Percentage(50);
           foreach (HierarchyEntity hierarchyEn in hierarchyValueList)
           {
               list.ID = "Hierarchy";
               list.Items.Add(hierarchyEn.Hname);
               list.Width = Unit.Percentage(65);
           }
           list.Items.Add("All");
       }
       else
       {
           foreach (MASTERTYPEEntity masterTypeEn in labelValueList)
           {
               list.ID = masterTypeEn.TypeName;
               label1.Text = masterTypeEn.TypeName;
               label1.Width = Unit.Percentage(60);
               label1.Height = Unit.Percentage(50);
           }

           foreach (MasterValueEntity masterValueEn in attributeValueList)
           {

               list.AutoPostBack = true;
               list.Items.Add(masterValueEn.TypeDesc);
               list.Width = Unit.Percentage(65);

           }
           list.Items.Add("All");
       }



       PlaceHolder1.Controls.Add(label1);

       PlaceHolder2.Controls.Add(list);


       session.Close();
       NHibernateSessionManager.Instance.CloseSession();
   }


Regards
Vidhya
Questionchange datetime format Pin
venkat86_ece21-May-08 1:08
venkat86_ece21-May-08 1:08 
AnswerRe: change datetime format Pin
Christian Graus21-May-08 1:09
protectorChristian Graus21-May-08 1:09 
GeneralRe: change datetime format Pin
venkat86_ece21-May-08 1:19
venkat86_ece21-May-08 1:19 
GeneralRe: change datetime format Pin
Christian Graus21-May-08 1:22
protectorChristian Graus21-May-08 1:22 
GeneralRe: change datetime format Pin
venkat86_ece21-May-08 1:41
venkat86_ece21-May-08 1:41 
GeneralRe: change datetime format Pin
Christian Graus21-May-08 1:43
protectorChristian Graus21-May-08 1:43 
AnswerRe: change datetime format Pin
gnjunge21-May-08 21:07
gnjunge21-May-08 21:07 
AnswerRe: change datetime format Pin
gnjunge21-May-08 21:15
gnjunge21-May-08 21:15 
QuestionProblem in Postback Pin
aaraaayen21-May-08 1:02
aaraaayen21-May-08 1:02 
AnswerRe: Problem in Postback Pin
Christian Graus21-May-08 1:05
protectorChristian Graus21-May-08 1:05 
Question/ in sql statement Pin
eyeseetee21-May-08 0:41
eyeseetee21-May-08 0:41 
AnswerRe: / in sql statement Pin
Christian Graus21-May-08 1:07
protectorChristian Graus21-May-08 1:07 
GeneralRe: / in sql statement Pin
eyeseetee21-May-08 1:22
eyeseetee21-May-08 1:22 
GeneralRe: / in sql statement Pin
Christian Graus21-May-08 1:26
protectorChristian Graus21-May-08 1:26 
GeneralRe: / in sql statement Pin
eyeseetee21-May-08 2:20
eyeseetee21-May-08 2:20 
GeneralRe: / in sql statement Pin
Guffa21-May-08 7:07
Guffa21-May-08 7:07 
Questionif img1.src="", set random image through Response.BinaryWrite() Pin
Vsree21-May-08 0:34
Vsree21-May-08 0:34 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.