Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
353 views
Hello

I'm trying to simulate the click on the folder on a RadFileExplorer, i can find the node and select it (the value is passed from a combo box), on SelectedIndexChaged, but i cannot find the way to reload the content of the RadFileExplorer from javascript, there is any way to do this?

my javascript code is:

function

 

onSelectedIndexChanged(sender, eventArgs)

 

{

 

var item = eventArgs.get_item();

 

 

var oExplorer = $find("<%=RadFileExplorer1.ClientID%>");

 

 

var oTree = oExplorer.get_tree();

 

 

if (oTree.findNodeByText(sender.get_value()))

 

{

 

var selectedNode = oTree.findNodeByText(sender.get_value());

 

selectedNode.select();

// Here i want to simulate the node click event...
}

 

else

 

alert(

'Folder not found');

 

}

Thanks in advance.

Miquel Frances Sitja
Top achievements
Rank 1
 answered on 23 Mar 2010
7 answers
127 views
Hi,

I can't get TimeSlotContextMenus to work, I get a script error saying that "'this._weekModels.0' is null or not an object".

  <Telerik:RadScheduler runat="server" ID="uxScheduler" 
                        DataKeyField="ActivityID" DataEndField="EndDateTime" DataStartField="StartDateTime"   
                        DataSubjectField="Description" HoursPanelTimeFormat="HH:mm" 
                        DayHeaderDateFormat="yyyy-MM-dd" 
                        FirstDayOfWeek="Monday" LastDayOfWeek="Friday" Height="100%" 
                        SelectedView="DayView" ShowDateHeaders="false" ShowResourceHeaders="true" ShowHeader="false" 
                        ShowFooter="true" MinutesPerRow="30" >             
    <MultiDayView UserSelectable="false" NumberOfDays="1" /> 
    <DayView UserSelectable="false" /> 
    <WeekView UserSelectable="false" /> 
    <MonthView UserSelectable="false" /> 
    <TimelineView UserSelectable="false" /> 
    <AppointmentTemplate> 
      <IMSC:ActivityItem ID="uxActivityItem" runat="server" ActivityID='<%#Bind("ID") %>' /> 
    </AppointmentTemplate> 
    <AppointmentContextMenus> 
      <Telerik:RadSchedulerContextMenu runat="server" ID="uxAppointmentMenu">  
        <Items> 
          <Telerik:RadMenuItem runat="server" Text="Open/Edit" value="edit" /> 
          <Telerik:RadMenuItem runat="server" IsSeparator="true" /> 
          <Telerik:RadMenuItem runat="server" Text="Delete" Value="delete" /> 
          <Telerik:RadMenuItem runat="server" IsSeparator="true" /> 
          <Telerik:RadMenuItem runat="server" Text="Cut" Value="cut" /> 
          <Telerik:RadMenuItem runat="server" Text="Copy" Value="copy" /> 
        </Items> 
      </Telerik:RadSchedulerContextMenu> 
    </AppointmentContextMenus> 
    <TimeSlotContextMenus> 
      <Telerik:RadSchedulerContextMenu runat="server" ID="uxTimeSlotMenu">  
        <Items> 
          <Telerik:RadMenuItem runat="server" Text="Create Activity" Value="create" /> 
          <Telerik:RadMenuItem runat="server" IsSeparator="true" /> 
          <Telerik:RadMenuItem runat="server" Text="Paste" Value="paste" /> 
        </Items> 
      </Telerik:RadSchedulerContextMenu> 
    </TimeSlotContextMenus> 
  </Telerik:RadScheduler> 
What I'm doing is keeping the Schedular in DayView and create resources for each date I actually want to show, this is so that it can display dates for non-consecutive days. I don't know if this has something to do with it, but the context menu for a time slot is not coming up. This has totally halted my project and I need to get this fixed.
Peter
Telerik team
 answered on 23 Mar 2010
1 answer
108 views
Hi ,
We are using RadControls_for_ASP.NET_AJAX_2010_1_309_dev in our site. In RadGrid control we are using MultiRowSelect property and also using context menue with it. If one row is selected and on other row if we right click , then second row also get selected. We want to deselect first row and select second row on right click.
May be we are trying to deselect any number of selected rows (could be 1 or more), on right click out side of that selection group. Can you please help us that how we can resolve this problem.

Regards,
Zeeshan
Yavor
Telerik team
 answered on 23 Mar 2010
3 answers
146 views
Hi

I am trying to trigger the ShowDialog function from behind the code?

reg

D

<%@ Page Language="VB" AutoEventWireup="false" CodeFile="Default2.aspx.vb" Inherits="Default2" %> 
 
<%@ Register Assembly="RadWindow.Net2" Namespace="Telerik.WebControls" TagPrefix="radW" %> 
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> 
<html xmlns="http://www.w3.org/1999/xhtml"
<head id="Head1" runat="server"
    <title>Untitled Page</title> 
</head> 
<body> 
    <form id="Form1" method="post" runat="server"
    <p> 
        <b>Returning multiple Values From a Dialog</b> 
        <br /> 
    </p> 
    <script type="text/javascript"
        //Show the window 
        function ShowDialog() { 
            var oWnd = window.radopen(null, "DialogWindow"); 
            oWnd.SetUrl(oWnd.GetUrl()); 
            return oWnd; 
        } 
         
        //Called when a window is being shown. Good for setting an argument to the window  
        function OnClientShow(radWindow) { 
            //Create a new Object to be used as an argument to the radWindow 
            var arg = new Object(); 
            //Using an Object as a argument is convenient as it allows setting many properties. 
            arg.NameValue = document.getElementById("NameArea").value; 
            arg.ProfessionValue = document.getElementById("ProfessionArea").value; 
 
            //Set the argument object to the radWindow       
            radWindow.Argument = arg
        } 
 
        function CallBackFunction(radWindow, returnValue) { 
            if (returnValue.NameValue) document.getElementById("NameArea").value = returnValue.NameValue; 
            if (returnValue.NameValue) document.getElementById("ProfessionArea").value = returnValue.ProfessionValue; 
        } 
 
        // Called when a window is being closed. 
        function OnClientClose(radWindow) { 
            //Another option for passing a callback value 
            //Set the radWindow.Argument property in the dialog 
            //And read it here --> var oValue = radWindow.Argument;                                      
            //Do cleanup if necessary 
        }    
                             
    </script> 
    <asp:Label ID="InjectScript" runat="server" Width="410px"></asp:Label> 
    <p> 
        Text to be modified from the dialog: 
        <br /> 
        Name: 
        <textarea id="NameArea" rows="1" cols="20">John Smith</textarea> 
        <br /> 
        Profession:<textarea id="ProfessionArea" rows="5" cols="20">VB Developer</textarea> 
        <asp:Button ID="Button1" runat="server" Text="Button" /> 
        <br /> 
        <button class="Button" style="width: 250px" onclick="ShowDialog();return false;" 
            type="button"
            Show dialog (force dialog refresh)</button> 
    </p> 
    <p> 
        (Open by client script) 
        <br /> 
        <radW:RadWindowManager ID="Singleton" runat="server" OnClientClose="OnClientClose" 
            OnClientShow="OnClientShow" ClientCallBackFunction="CallBackFunction" VisibleOnPageLoad="false"
            <Windows> 
                <radW:RadWindow ID="DialogWindow" OffsetElementId="NameArea" Left="250px" Modal="true" 
                    runat="server" Width="370px" Height="310px" Title="User List Dialog" NavigateUrl="./Dialog.aspx"
                </radW:RadWindow> 
            </Windows> 
        </radW:RadWindowManager> 
    </p> 
    <p> 
        &nbsp;</p> 
    <div style="width: 456px; height: 260px; text-align: justify"
        <p> 
            The example is based on <strong>t</strong>elerik's demo <href="http://www.telerik.com/r.a.d.controls/Window/Examples/DialogReturnValue/DefaultCS.aspx" 
                target='_blank"'>Returning Values From A Dialog </a>and <strong>t</strong>elerik's 
            KB article <href="http://www.telerik.com/Default.aspx?PageId=2514&amp;b454K=xg8&amp;b454T=o8c" 
                target="_blank">(ID#664) Providing an argument to a dialog. Return value from a 
                dialog, assign and invoke callback function</a>
        </p> 
        <p> 
            The approach is the same as explained in the KB article above and the only difference 
            is that instead of only one, we are passing two values to and from the dialog. If 
            you need more values to be passed - the logic stays the same. 
        </p> 
        <p> 
            For more information, please check the comments in the code. 
        </p> 
    </div> 
    </form> 
</body> 
</html> 
 

Imports Telerik.WebControls 
 
Partial Class Default2 
    Inherits System.Web.UI.Page 
 
     
    Protected Sub Button1_Click(ByVal sender As ObjectByVal e As System.EventArgs) Handles Button1.Click 
        InjectScript.Text = "<script type='text/javascript'>ShowDialog()</" + "script>" 
    End Sub 
End Class 
 

Tsvetoslav
Telerik team
 answered on 23 Mar 2010
1 answer
129 views
Hello,

We're in the process of replacing our old tree control with a new one. We've implemented the expand mode as serversidecallback but there is a noticeable delay in comparison to the old tree (several seconds). The old tree control uses web service node expansion. Although this feature is available with the Telerik TreeView control, it is severely limited. We need to not only add the child nodes, but also register other client data/scripts. With ServerSideCallBack, we're writing our dynamic javascript to the Category field. Could you suggest how we could get similar results from WebService expand mode?

e.g.
void AddNodeForWebServiceExpand(...)
{
RadTreeNodeData n;
n.Text = "My node";
n.Value = "N0";

/* add dynamic js */
n.<some string property> = "alert('name = My node; value = N0; extra data = <some extra data>')";
}

Regards,
Paul
Veselin Vasilev
Telerik team
 answered on 23 Mar 2010
1 answer
199 views
Hi Telerik Team !


I have a two RADGRID on to my ASPX page.

I want to show the AJAX LOADING IMAGE when I perform any ACTION(sorting,reordering,filtering,selection) on to my RAD GRID.

Right now ,Iam able to do so but the problem is that Iam not able to get the full postback on to the server as a result of which

the records that is to be shown on the other GRID are not showing up.  


By the way ,

I have used the below code to ajaxify my second grid as I dont want a POST for my second GRID.

 <telerik:RadAjaxManager ID="RadAjaxManager1" runat="server"
                    <AjaxSettings> 
                        <telerik:AjaxSetting AjaxControlID="PermissionListRadGrid"
                            <UpdatedControls> 
                                <telerik:AjaxUpdatedControl ControlID="PermissionListRadGrid" LoadingPanelID="RadAjaxLoadingPanel1" /> 
                            </UpdatedControls> 
                        </telerik:AjaxSetting> 
                    </AjaxSettings> 
                </telerik:RadAjaxManager> 


Its working fine & I need is to show the loading image with full postback on to the server so as to get the relevant data on to the second grid based on the first grid.

How to do this ?

Anyone please help !

Lenny_shp
Top achievements
Rank 2
 answered on 23 Mar 2010
3 answers
137 views
Hi

is it possible to do the following?

I have a radgrid where one of the columns has the this values:  Not Stared, In Progress, Complete, Ongoing

like this


No          Status

1          Not Started
2          In Progress
3          Ongoing
4          In Progress
5          In Progress
6          Complete


I have a custom filter on the status column (a dropdown with 4 items) so I can filter on the 4 different types.
The Customer now wants a 5th item in the filter dropdown, and this 5th should get back all the records that are not Complete.

How could I make this happen?


Thanks


Kati

Tsvetoslav
Telerik team
 answered on 23 Mar 2010
2 answers
190 views
Is there a property to disable the client validation (yellow triangle and red border) in raddatepicker, it doesnt look weel in my layout, and I have built my own customized validation routine.

If not, how can I do that?

Regards
André
André Freitas
Top achievements
Rank 1
 answered on 23 Mar 2010
5 answers
195 views
I would like to display the items from the 2nd level onwards. How can this be accomplished?
Peter
Telerik team
 answered on 23 Mar 2010
7 answers
167 views
Hi,

   I am using RadGrid to display items. I use webusercontrol to edit Grid data. Everything was working fine.
After I added Ajax, the Grid Works fine, but the Update/delete is not working. I also use <asp:LinkButton for showing the edit form.

Can someone please help me?

<MasterTableView DataKeyNames="IDR_ID" GridLines="None" Width="100%" CommandItemDisplay ="Top" InsertItemDisplay="Top" InsertItemPageIndexAction="ShowItemOnCurrentPage">   
              <CommandItemTemplate> 
                    <div style="padding: 5px 5px;"
                        &nbsp;&nbsp;&nbsp;&nbsp; 
                        <asp:LinkButton ID="btnEditSelected" runat="server" CommandName="EditSelected" Visible='<%# RadGrid1.EditIndexes.Count == 0 %>'><b>Edit selected</b></asp:LinkButton>&nbsp;&nbsp;&nbsp;&nbsp; 
                        <asp:LinkButton ID="btnCancel" runat="server" CommandName="CancelAll" Visible='<%# RadGrid1.EditIndexes.Count > 0 || RadGrid1.MasterTableView.IsItemInserted %>'><b>Cancel editing</b></asp:LinkButton>&nbsp;&nbsp; 
                        <asp:LinkButton ID="LinkButton2" runat="server" CommandName="InitInsert" Visible='<%# !RadGrid1.MasterTableView.IsItemInserted %>'><b>Add new</b></asp:LinkButton>&nbsp;&nbsp;&nbsp;&nbsp; 
                        <asp:LinkButton ID="LinkButton1" OnClientClick="javascript:return confirm('Delete selected IDR?')" runat="server" CommandName="DeleteSelected"><b>Delete selected IDR</b></asp:LinkButton>&nbsp;&nbsp; 
                        <asp:LinkButton ID="LinkButton4" runat="server" CommandName="RebindGrid"><b>Refresh IDR list</b></asp:LinkButton> 
                    </div> 
                </CommandItemTemplate>  


Thanks,
Rita



Tsvetoslav
Telerik team
 answered on 23 Mar 2010
Narrow your results
Selected tags
Tags
+? more
Top users last month
Hiba
Top achievements
Rank 1
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Max
Top achievements
Rank 1
Veteran
Iron
Alina
Top achievements
Rank 1
Rakhee
Top achievements
Rank 1
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Hiba
Top achievements
Rank 1
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Max
Top achievements
Rank 1
Veteran
Iron
Alina
Top achievements
Rank 1
Rakhee
Top achievements
Rank 1
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?