FreeTextBox

The no. 1 free ASP.NET HTML Editor.
Welcome to FreeTextBox Sign in | Join | Help
in Search

FreeTextBox Halts Controls On Page Until Load

Last post 09-04-2008, 7:20 PM by JJJB. 2 replies.
Sort Posts: Previous Next
  •  09-02-2008, 10:01 PM 9415

    FreeTextBox Halts Controls On Page Until Load

    I am having an issue in which I thought I had found a problem.  See this thread:
    http://freetextbox.com/forums/thread/9317.aspx

    I am using Firefox 3.0.1 and IE 7.0 with FreeTextBox 3.1.6.  The below works just fine in IE, but not in Firefox.

    I have an ASP/AJAX page with a drop down list, a couple Gridviews with edit and delete buttons and two panels.  One panel contains my FreeTextBox control, and is collapsed by default.  Since the panel is collapsed, the FreeTextBox is not shown on the initial page load.

    The problem is that until the panel is expanded (and thus showing the FreeTextBox), none of the other controls (drop down list, buttons, etc.) fire any events.  Furthermore, if the panel is expanded by default, things work as expected.  If the panel is collapsed manually (hiding the FreeTextBox), the controls will not fire events.

    I tried getting around this in the above post, but it only works on the initial page load.

    Please help with any suggestions!

    Here is the relavent asp code:
    (removed)

  •  09-03-2008, 10:15 PM 9418 in reply to 9415

    Re: FreeTextBox Halts Controls On Page Until Load

    My workaround for this is as follows:

    1) Add a placeholder for the FreeTextBox in the ASP page
    2) Add a handler for when the FreeTextBox is to be displayed (i.e. OnClick)
    3) Programmatically add a FreeTextBox to the placeholder, thus displaying it
    4) Kill off the FreeTextBox when done

    In my case, I added an AJAX ModalPopupExtender to display the FreeTextBox.  When I click the button wired up to the ModalPopupExtender, I programmatically add the FreeTextBox to the ModalPopupExtender, and the ModalPopupExtender kills it off when the user exits.

    This works in IE, Firefox, and Google Chrome (except the presentation of the FreeTextBox is messed up).

    PITA!!!!!

  •  09-04-2008, 7:20 PM 9430 in reply to 9418

    Re: FreeTextBox Halts Controls On Page Until Load

    Just in case anyone is actually listening...

    I ran into another problem with this, but came out with a better solution.  Instead of using a placeholder as stated above, place the FreeTextBox like you normally would but set Visible="false", which prevents it from doing anything on the page.  When you need it displayed, set Visible="true", do what you need to do, and set Visible="false" when you get the text from the FreeTextBox and it no longer needs to be on the page.  Of course, programmatically adding the FreeTextBox is no longer needed.

    My issue with my solution in post #2 was that the FreeTextBox was being forced to a regular TextBox, and I could not read the HTML-formatted text.

    I'm done with what I needed the FreeTextBox for, which is a good thing!

View as RSS news feed in XML
www.freetextbox.com