Welcome Guest Search | Active Topics | Sign In | Register

ColorPicker inside asp.net panel does not appear when clicked Options
David Butz
Posted: Thursday, June 11, 2009 6:26:07 PM
Rank: Newbie
Groups: Member

Joined: 6/11/2009
Posts: 4
I am trying to integrate the colorpicker tool into any existing application which uses panel controls as containers to hold UI elements used to perform specific tasks.

The asp.net panels are all invisible at page_Load and when I click a menu item to call up a certain task panel, the colorpicker control appears but does not respond to any clicks to show the palette.

If I set the panel as visible initially so it is shown on page_Load without the user asking for that task panel, then the colorpicker works when clicked.

Any ideas on how to work around this?

Thanks,
david Butz
GIS Software Developer
Davis Demographics & Planning
eo_support
Posted: Thursday, June 11, 2009 6:35:05 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,194
Hi,

Do you have the Panel inside an ASP.NET AJAX UpdatePanel? If so please try to place an eo:ScriptManager control outside of all UpdatePanels. The idea is so that our JavaScript code got hooked up before any of the Panel is set to visible.

Thanks!
David Butz
Posted: Thursday, June 11, 2009 7:04:35 PM
Rank: Newbie
Groups: Member

Joined: 6/11/2009
Posts: 4
Thanks for the quick reply.

I had not previously used the eo:scriptmanager control. Is this needed to make the colorpicker work in an async page?

I am actually using the colorpicker control in a special 3rd party panel control (that is extended from the asp.net panel) that is already ajax enabled so no, I am not using an UpdatePanel in my app.

I tried adding the scriptmanager control both inside and outside the panel that contains my colorpicker but that didnt seem to work.

Thanks,
David
eo_support
Posted: Thursday, June 11, 2009 7:56:03 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,194
Hi,

It shouldn't have anything to do with async page. It has to do with AJAX. You may wish to consider replacing the 3rd party panel control with ASP.NET UpdatePanel or our CallbackPanel. The reason is that not every control will work with every AJAX panel. Usually there is no problem for simple controls that only renders HTMLs. But for complex control that also renders JavaScript, it is often necessary for the control and the AJAX panel to work together, in another word, the control needs to "know" the AJAX panel.

It is obviously not possible for our control to know and work with every existing third party AJAX panel. We do support ASP.NET AJAX UpdatePanel very well since it is from MS. We also support our own CallbackPanel. CallbackPanel is very similar to UpdatePanel, but with a few advantage when working with our own controls because they know each other.

I understand that it maybe quite an undertaking for you to replace your current third party AJAX Panel, but I believe that is worth it because UpdatePanel is the dominate AJAX solution now. It’s probably the most widely used and supported solution on ASP.NET.

Update: You may also want to try placing an additional eo:ColorPicker before (outside) your Panel, but inside an invisible div so that it is not visible:

Code: HTML/ASPX
<div style="display:none">
    <eo:ColorPicker ....></eo:ColorPicker>
</div>


This will make sure all JavaScript files needed by the ColorPicker correctly rendered. That does not guarantee it will work, but often that is all that is needed.

Thanks!
David Butz
Posted: Tuesday, June 16, 2009 1:10:43 PM
Rank: Newbie
Groups: Member

Joined: 6/11/2009
Posts: 4
Thanks for the help.

To develop the map based site I am stuck using this company's ajax enabled floating panel control. However, I have embedded more panels inside this floating panel to group controls together so I can show/hide them easier. I converted these panels to updatepanels and now your control seems to work inside my app.

However, the update panel renders its name in the webpage. Have you ever seen anything like this before? It rendered "26664|updatePanel|fpSymbology_singleColor|" at the top of the updatePanel control. Any way to get rid of that?

Thanks again,
David

eo_support
Posted: Tuesday, June 16, 2009 1:18:52 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,194
Hi,

It is normal for an update panel to fetch such text from the server, but I do think you should contact the vendor of your panel control for such problems. While almost all update panel work alike, every one of them is a different animal and we have no way of knowing their internal works, let alone to find a solution for you.

Thanks
David Butz
Posted: Tuesday, June 16, 2009 1:26:25 PM
Rank: Newbie
Groups: Member

Joined: 6/11/2009
Posts: 4
Thanks so much for the quick replies. You have been quite helpful.

David


You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.