jbisono 51 Posting Pro in Training

Hello everyone.

The problem: I am developing a form that i have to validate some fields against the database. For this particular scenario lets say the Part ID field, I do not want to create a dropdownlist with all part id because is too big. maybe i can let people write down the part id in a textbox control and then validate, but sometimes they do not know the part id. Anyway my solution is create a custom control which i can display into a modalpopextender, this custom control contains a gridview control with the ids and description parts with sort, page and filter option.

now what i want to be able to do is when client select a specific part from the gridview, fill the PartId textbox control automatically and the modalpopextender will disappear.

Can you address me to right direction. so far I have the custom control, in the form i have this code.

<asp:TextBox ID="TextBox1" runat="server"></asp:TextBox>
 <asp:Button ID="Button1" runat="server" Text="Button" />
 <asp:Panel ID="pnlVendor" runat="server" CssClass="selector" style="display:none" >
//the code right below is my custom control
        <ew:Vendor ID="vndSelect" runat="server" />
    </asp:Panel>
    <cc1:ModalPopupExtender ID="ModalPopupExtender1" runat="server" PopupControlID="pnlVendor" TargetControlID="Button1" >
    </cc1:ModalPopupExtender>

again when the client click button1 then pnlVendor will popup which contain my gridview with the parts when they hit select in the pop up the partid will show in TextBox1.

thanks for any help.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.