This is a migrated thread and some comments may be shown as answers.

[Solved] OnClientClick and RadScriptBlock

2 Answers 129 Views
Ajax
This is a migrated thread and some comments may be shown as answers.
Phil
Top achievements
Rank 2
Phil asked on 02 Mar 2010, 01:38 AM
Hi
I have OnClientClick set to some dynamic js on a RadGrid and it is to calls js in a RadScriptBlock.  But it does not work.  I take the js out of the RadScriptBlock and then it works.  What is the problem?
Phil

2 Answers, 1 is accepted

Sort by
0
Accepted
Pavlina
Telerik team
answered on 02 Mar 2010, 08:06 AM
Hi Phil,

If you want to place the javascript inside the page markup, and you are using AJAX, you need to put your code inside a RadScriptBlock control, so the script gets properly registered on page after AJAX. Other than that, the code should work OK.

For more information, refer to this help article:
RadCodeBlock and RadScriptBlock

Greetings,
Pavlina
the Telerik team

Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
0
Phil
Top achievements
Rank 2
answered on 05 Mar 2010, 06:32 PM
Last night I tried the problem in a small example and I could not reproduce it, so my fellow programmer has done something else.
Sorry Phil
Tags
Ajax
Asked by
Phil
Top achievements
Rank 2
Answers by
Pavlina
Telerik team
Phil
Top achievements
Rank 2
Share this question
or