Fail to connect to DB

2 posts, 0 answers
  1. Zal
    Zal avatar
    10 posts
    Member since:
    Apr 2007

    Posted 17 Apr 2008 Link to this post

    I have added the Tooltip control using the Load on demand as an emaple.

    On my usercontrol on UpdatePanel, i have tried to connect ot the db, but without success.

    I pass in the a paramter into the usercontrol which i then pass into a string method, which then gets assigned to the literal control on the usercontrol.

    my code looks similar to

    private string _claimNr;
           
            public string ClaimNr
            {
                get { return _claimNr; }
                set { _claimNr = Convert.ToString(value); }
            }

        protected void Page_Load(object sender, EventArgs e)
        {
                litResults.Text =  BuildPopUp(ClaimNr);
        }

            protected string BuildPopUp(string claimNr) {
                StringBuilder objSB = new StringBuilder();
    // DB stuff to go here
    return objSB.Tostring();
    }

    When  itry to connect to the db in the dynamic popup on the browser screen i get a blank popup.

    I know my connection isnt an issue, and neither is my sql.
    As a test i did
    objsb.append("The claim nr is: " + claimNr) and tried to return this and it worked.

    Please help am i missing something important.

    Many thanks in advance

    Zal

  2. Svetlina Anati
    Admin
    Svetlina Anati avatar
    2795 posts

    Posted 21 Apr 2008 Link to this post

    Hello Zal,

    I am not quite sure what may cause the problem you experience and I need to examine your particular project. For the time being I can only make assumptions. I think that the problem may be caused by incorrect or missing databinding. I also recommend testing the project without the UpdatePanel and trying to detect whether the ajax request is causing the issue.

    For your convenience I send you a sample example of the desired functionality - you can find it in the attached archive file.
    In case you still experience problems with the implementation, please, open a new support ticket and send us a sample, fully running project (including a database) with detailed explanation of the information that should be displayed and we will modify it in order to meet your requirements. 


    Best wishes,
    Svetlina
    the Telerik team

    Instantly find answers to your questions at the new Telerik Support Center
Back to Top