i know this is a silly question, but i have a splitter on a page and am trying to call a javascript function to scroll the splitter to the bottom on page load.
var splitter = $find("<%= RadSplitter1.ClientID %>");
I tried the code and I am able to get reference to RadSplitter clientside object using above code. Could you provide the version of RadControl that you are using?
Here is the documentation on how to get the client side object in RadSplitter for ASP.NET version: Basics
And here is the documentation on how to get the client side object in RadSplitter for ASP.NET AJAX version: Client-Side Basics
Are you placed the RadSplitter in any UserControl?
I do not have the splitter in a user control. A simple page with a splitter and a script.
<scripttype="text/javascript">
var splitter = $find("<%= RadSplitter1.ClientID %>");
alert(splitter);
</script>
always returns null
0
Tsvetie
Telerik team
answered on 02 Oct 2009, 02:42 PM
Hi Michael Constantine,
The client objects for the RadControls are created on the Sys.Application.init event. That is why, in case you want to get a reference to a RadControl client object, you can do this after the init event. For example:
<script type="text/javascript">
function pageLoad()
{
var splitter = $find("<%= RadSplitter1.ClientID %>");