Portal Engine Questions on portal engine and web parts.
Version 6.x > Portal Engine > Regarding the bizform drop down control. View modes: 
User avatar
Member
Member
sansugoi_sayounara-hotmail - 3/1/2012 11:00:29 PM
   
Regarding the bizform drop down control.
Hi all,

I want to display a dropdown on my home page and when user select any value from dropdown then it should move to the selected page once the value from dropdown is selected , I dont' want button to click.
It should redirect on selecting the vlaues from dropdown.

This is very very urgent!!
please guide me.

Thanks
Sansugoi

User avatar
Member
Member
kentico_michal - 3/2/2012 4:16:30 AM
   
RE:Regarding the bizform drop down control.
Hello,

You need to enable the AutoPostBack property of the DropDownList control so that an automatic post back occurs when the user changes the selected value without having to click some button. Then, you can redirect user in the SelectedIndexChanged event based on what value the user has selected:


<asp:DropDownList runat="server" ID="ddl" OnSelectedIndexChanged="OnChanged" AutoPostBack="true" ></asp:DropDownList>

protected void OnChanged(object sender, EventArgs e)
{
// redirect the user if necessary
}


Anyway, you can use the URLHelper.Redirect(string Url) method to redirect the user.

Best regards,
Michal Legen

User avatar
Member
Member
sansugoi_sayounara-hotmail - 3/2/2012 4:21:17 AM
   
RE:Regarding the bizform drop down control.
Hi Micheal,

Thanks for rply,

Where to add this code

<asp:DropDownList runat="server" ID="ddl" OnSelectedIndexChanged="OnChanged" AutoPostBack="true" ></asp:DropDownList>protected void OnChanged(object sender, EventArgs e){ // redirect the user if necessary}



Thanks
SAnsugoi

User avatar
Member
Member
kentico_michal - 3/2/2012 4:51:34 AM
   
RE:Regarding the bizform drop down control.
Hello,

You can, for example, create a new custom web part for this purpose, as it is described in documentation: Developing web parts.

Best regards,
Michal Legen