Telerik Forums
UI for ASP.NET AJAX Forum
3 answers
211 views
hi,

i have build a tree based on load on demand method (ie, while expanding the root node only the child nodes are getting populated).

now my problem is,

i want to search the employee node in the treeview.

at first, only one node is there in a treeview. i need to call the node_Expand event every time based on the hierarchy of the employee.

the tree view is adding nodes for the first level.next time it gives nullreference exception.
Ex,
---
AAAA
--BBB
-------B1
-------B2
--CCC
--DDD
-------D1
-------D2
------------D21
--EEE

in the above tree i am going to find D21. first it builds the first level ie, AAA,BBB,CCC,DDD,EEE  without error. the next level D1,D2 also bulit without error.next D2 node expanding time it gives the error.

how can i solve this. how to find the employee.

thanks,
mano.

Yana
Telerik team
 answered on 27 Feb 2009
5 answers
819 views
Hi , 

I am trying to validate a date picker if an invalid date is entered. It becomes red and with the help of script i can pop up an error meg but that still doesnt help me stop the page from being saved (ie postback). IS there any way i could make it work as the comparevalidator would work ie restricting the page from being posted back if the validation fails. 

 Or in my error script function how can i set the focus back to the control after the popup so that everytime the user tries to come out of the datepick with an invalid date i pop the error msg and the focus goes back to it.

Below is my code.

        

<

rad:RadDatePicker ID="DtGrid" runat="server" MinDate="2000-01-01" MaxDate="2014-12-31"   DatePopupButton-ImageUrl="~/Images/calendar_small.gif" DatePopupButton-HoverImageUrl="~/Images/calendar_small.gif" SharedCalendarID="sharedCalendar">

<DateInput runat="server">

<ClientEvents OnError ="Error" />

</DateInput>

</rad:RadDatePicker>


and this my script 


<

script language="javascript" type="text/javascript">

function

Error(sender, args)

{

alert ("Enter a Valid Date in MM/DD/YYYY Format");

}

</

script>



Any help appriciated.

Thanks

Missing User
 answered on 27 Feb 2009
10 answers
241 views
I'm having a combobox (with load on demand enabled) and a ajax panel on my page. When the ajax panel is loading, the combobox is unable to retrieve the items. How can I solve this, so the user can open the combobox while the panel is loading?

You can use the following code to reproduce the problem. Just click the reload button, and open the combobox immediately afther that.

<telerik:RadScriptBlock runat="server" ID="scriptBlock"
<script type="text/javascript"
function reload()  
    $find("<%=pnl.ClientID %>").ajaxRequest(); 
</script> 
</telerik:RadScriptBlock> 
 
<script runat="server"
     
    Protected Sub pnlAjaxRequest(ByVal sender As Object, ByVal e As EventArgs) 
 
        Threading.Thread.Sleep(1000) 
 
    End Sub 
     
    Protected Sub cmbTestItemsRequested(ByVal sender As Object, ByVal e As EventArgs) 
         
        Dim cmb = DirectCast(sender, RadComboBox) 
        cmb.DataSource = New String() {"John Doe", "Jane Doe", "Baby Doe"} 
        cmb.DataBind() 
         
    End Sub 
     
</script> 
 
<asp:Button runat="server" ID="clickme" OnClientClick="reload(); return false;" Text="Reload" /> 
 
<telerik:RadComboBox runat="server" ID="cmbTest" OnItemsRequested="cmbTestItemsRequested" EnableLoadOnDemand="true"
</telerik:RadComboBox> 
       
<telerik:RadAjaxLoadingPanel runat="server" ID="loadingPanel"></telerik:RadAjaxLoadingPanel> 
<telerik:RadAjaxPanel ID="pnl" runat="server" LoadingPanelID="loadingPanel" OnAjaxRequest="pnlAjaxRequest"
    Lorem ipsum dolor sit amet, consectetur adipiscing elit. Aenean fermentum auctor lectus. Aliquam erat volutpat. Integer in tellus. Morbi vitae pede quis pede rutrum feugiat. Vestibulum et dui vel mauris placerat porta. In hac habitasse platea dictumst. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. Vivamus blandit. Maecenas hendrerit orci non turpis eleifend venenatis. Duis vitae orci eget turpis tristique venenatis. Aliquam vitae libero vel libero pharetra bibendum. Mauris hendrerit hendrerit mauris. Cras fringilla dolor in nibh. Duis gravida rhoncus tellus. Praesent eget orci. Duis ultrices leo non justo. Quisque egestas.        
</telerik:RadAjaxPanel> 

Yana
Telerik team
 answered on 27 Feb 2009
4 answers
287 views
Hi,

I'm trying to select rows and handle them serverside. I would like to trigger a postback on multiple row selecting by drag. I managed to do a postback with this code :

function RowSelected(row, eventArgs) {
        alert(row);
        __doPostBack('<%=skupineGrid.ClientID %>');

    }


It is triggered here <ClientEvents OnRowSelected="RowSelected" />.

Now I would like to do an update in the database for selected rows.

 foreach (GridDataItem item in skupineGrid.SelectedItems)
        {
          item.Selected = true;
          // bla bla
        }

How can I achive this?




Lukrs
Top achievements
Rank 2
 answered on 27 Feb 2009
8 answers
422 views
Hello,

I would like to disable the AddNewRecord button or possibly hide it from there and leave only the Refresh button.

This method/property is not available from the CommandItemSettings!



Thanks
Olo
Top achievements
Rank 1
 answered on 27 Feb 2009
2 answers
174 views
Hello,

I am working on several grids that contain a date column.  In the database the date/time is in UTC. I have a method that converts the UTC date to any time zone specified. I have a control that allows the user to select  a time zone.  I would like to show the date in the specified time zone. If the user changes the time zone the date column updates.

My prototype creates a DataTable in code behind and calculates the data as it populates the rows.

Do you think this is the best way? It seems like there should be a way to hook into the onDisplay event for that field and modify it as it is being displayed.  That would be cleaner and allow use of the field property editors.

Thanks

Barry

Barry
Top achievements
Rank 1
 answered on 27 Feb 2009
3 answers
285 views
hi,

how to put plus symbol in front of all nodes in a treeview.

is there any property .


thanks,
mano
Yana
Telerik team
 answered on 27 Feb 2009
1 answer
83 views
How
Rumen
Telerik team
 answered on 27 Feb 2009
9 answers
324 views
I've got a combobox with EnableLoadOnDemand turned on and ShowMoreResultsBox as true.  When I click on the combobox or click to show more results, our validation code gets called.  I've tried setting CausesValidation to false on the combobox, but this does not have any effect.  What can I do?
Simon
Telerik team
 answered on 27 Feb 2009
1 answer
59 views
Help
Rumen
Telerik team
 answered on 27 Feb 2009
Narrow your results
Selected tags
Tags
+? more
Top users last month
Shiori
Top achievements
Rank 2
Iron
Tien
Top achievements
Rank 1
Iron
Robert
Top achievements
Rank 1
Rob
Top achievements
Rank 4
Bronze
Bronze
Iron
Geoff
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Top users last month
Shiori
Top achievements
Rank 2
Iron
Tien
Top achievements
Rank 1
Iron
Robert
Top achievements
Rank 1
Rob
Top achievements
Rank 4
Bronze
Bronze
Iron
Geoff
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?