Advertisement
Help Keep Boards Alive. Support us by going ad free today. See here: https://subscriptions.boards.ie/.
If we do not hit our goal we will be forced to close the site.

Current status: https://keepboardsalive.com/

Annual subs are best for most impact. If you are still undecided on going Ad Free - you can also donate using the Paypal Donate option. All contribution helps. Thank you.
https://www.boards.ie/group/1878-subscribers-forum

Private Group for paid up members of Boards.ie. Join the club.

another ajax :-(

  • 09-07-2008 12:30PM
    #1
    Closed Accounts Posts: 317 ✭✭


    hi,
    I hope I can explain this clearly!

    I have a text box with extenders autocomplete and watertextmark extender.

    When the watermark extender is on and I select say an item on a datagrid, the textbox looks like it posts, so it disappears for a split second.
    I have the textbox in an ajax update panel.

    If I remove the extender and simply as a test put in some text in the textbox, hit select on my gridview there is no postback, it seems static, which is what I want ( I do have my textbox set to auto postback as I need it ) but just don't want the visibility to the user that it's refreshing or anything.

    Hope someone can help, thanks !


Comments

  • Registered Users, Registered Users 2 Posts: 2,494 ✭✭✭kayos


    Ahhhhhh maybe its just me but I would not be able to help you from your description.


  • Closed Accounts Posts: 317 ✭✭tiptap


    kayos wrote: »
    Ahhhhhh maybe its just me but I would not be able to help you from your description.

    I thought so :-)

    ok, let me start again

    The textbox I have has an autocomplete on it which is working fine.

    If I type in a name in the textbox and press enter, a list of people appear in my gridview.
    Now, if I type in another name in the textbox and press enter, again, my gridview is populated with new data AND there is NO page refresh. A smooth transition if you get me, I'm not sure of the techie term !

    Now, if I put in the watermark extender on the textbox, the gridview works fine but I notice that my textbox looks like it's posting back to the server, or it's refreshing or dissapearing for a split second.

    I hope that makes it more clear


  • Closed Accounts Posts: 1,444 ✭✭✭Cantab.


    Why don't you just post the code?


  • Closed Accounts Posts: 317 ✭✭tiptap


    Cantab. wrote: »
    Why don't you just post the code?


    here we go.

    I just did up a really simple example so you can see the problem.
    If you click on a page on the datagrid you can see the textbox with the watermark do something funny, whereas the normal text box is fine.



    <% Page Language="C#" AutoEventWireup="true" CodeFile="Default2.aspx.cs" Inherits="Default2" %>
    <%
    Register assembly="AjaxControlToolkit" namespace="AjaxControlToolkit" tagprefix="cc1" %>
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"&gt;
    <
    html xmlns="http://www.w3.org/1999/xhtml"&gt;
    <
    head runat="server">
    <title>Untitled Page</title>
    </
    head>
    <
    body>
    <form id="form1" runat="server">
    <div>

    <asp:SqlDataSource ID="SqlDataSource1" runat="server"
    ConnectionString="<%$ ConnectionStrings:hailConnectionString %>"
    SelectCommand="SELECT [firstname] FROM [PersonTBL]"></asp:SqlDataSource>
    <asp:ScriptManager ID="ScriptManager1" runat="server">
    </asp:ScriptManager>
    <br />
    <br />
    <br />
    <br />
    <br />
    <br />
    <asp:UpdatePanel ID="UpdatePanel1" runat="server">
    <ContentTemplate>
    <asp:GridView ID="GridView1" runat="server"
    AllowPaging="True" AutoGenerateColumns="False" DataSourceID="SqlDataSource1">
    <Columns>
    <asp:BoundField DataField="firstname"
    HeaderText="firstname" SortExpression="firstname" />
    </Columns>
    </asp:GridView>
    <br />
    <asp:TextBox ID="TextBox1" runat="server">standard</asp:TextBox>
    <br />
    <br />
    <asp:TextBox ID="TextBox2" runat="server"></asp:TextBox>
    <cc1:TextBoxWatermarkExtender ID="TextBox2_TextBoxWatermarkExtender"
    runat="server" Enabled="True" TargetControlID="TextBox2"
    WatermarkText="Ajax Water">
    </cc1:TextBoxWatermarkExtender>
    <br />
    </ContentTemplate>
    </asp:UpdatePanel>
    <br />

    </div>
    </form>
    </
    body>
    </
    html>


  • Closed Accounts Posts: 317 ✭✭tiptap


    I found this, exact same problem I'm having,

    no solution it appears !

    http://forums.asp.net/p/1123771/1761607.aspx#1761607


  • Advertisement
Advertisement