Telerik Forums
UI for ASP.NET AJAX Forum
6 answers
190 views
Hi,

first of all my problem.
I want to use RadFileExplorer to select directories. And I want to get a notification on server that a new folder got selected.
And further assume that I only show the Treeview - else I have no problems at all - I simply use OnFolderLoaded which works.
But when using only the treeview there is no OnFolderLoaded - BUT OnClientFolderChange fires in that situation.
So from a first point of view it looks as if I got what I need.

I handle my OnClientFolderChange like this:
function OnClientFolderChange(sender, args) {  

var

 

item = args.get_item();

 

   TellServerAboutSelectedElement("DIR:" + item.get_path());  
}  
 
function TellServerAboutSelectedElement(argument) {  
    var ajaxManager = $find("<%= RadAjaxManager.GetCurrent(Page).ClientID %>");  
    ajaxManager.ajaxRequest(argument);  
} 
So far so good - it does what I like - in some situations!!

When the FileExplorer has to load something (the selected folder contains sub-folders) this call breaks the FileExplorer.
I get a "never ending" loading animation.
So I guess that my ajax call interferes with the ajax call the FileExplorer makes.

Not that big problem - I only have to queue my call if the FileExplorer already is in an ajax call.
So the idea is like this:
function OnClientFolderChange(sender, args) {  
    var item = args.get_item();  
    if(nQueueCounter>0) {  
        EnqueuRequest("TellServerAboutSelectedElement", "DIR:" + item.getPath();  
        return;  
        }  
    TellServerAboutSelectedElement("DIR:" + item.get_path());  
}  
 
function ResponseEnded(sender, args) {  
    nQueueCounter--;  
    HandleQueuedCalls();  
}  
function RequestStarted(sender, args) {  
    nQueueCounter++;  
}  
 
function TellServerAboutSelectedElement(argument) {  
    var ajaxManager = $find("<%= RadAjaxManager.GetCurrent(Page).ClientID %>");  
    ajaxManager.ajaxRequest(argument);  
}  
 
This looks good - and the approach works (for an example) with a grid.
BUT - neither OnRequestStart nor OnResponseEnd is fired when RadFileExplorer makes ajax calls.

So it looks as if the RadFileExplorer bypasses RadAjaxManager - or doesn't handle it properly.
I never ran in such a situation - so I don't know if RadAjax generally requires "no concurrency handling" or if this is only the fact with RadFileExplorer.
Anyhow - with RadFileExplorer I need to synchronize my calls and the ones of the explorer - and this seems to be a problem since the needed events (requeststart - responseend) do not fire.

Could someone pleas give me any advice?

Regards

Manfred
ManniAT
Top achievements
Rank 2
 answered on 27 Apr 2009
1 answer
87 views
Currently, I am using ASP .NET MVC release 1.0 with RenderPartialRequest (link: http://blog.codeville.net/2008/10/14/partial-requests-in-aspnet-mvc/) and Telerik control in my project.
I was in stuck with using Telerik control. For example, I have a page will call RenderPartialRequest many times with the same params. Each call will render a View in Controller by invoke method of RenderPartialRequest.  Assumes that View contains some telerik controls like: RadInput, RadCalendar.
I do not know how to using telerik:RadScriptManager in this case. Because it is duplicated a lot.

Please help me with a solution for this scenerio.

Thanks.
Atanas Korchev
Telerik team
 answered on 27 Apr 2009
0 answers
89 views
I have a combo in the item template of the radgrid.
A required filed is also placed with a call out extender.
But the call style is lost.
How to change it?
kollam2003
Top achievements
Rank 1
 asked on 27 Apr 2009
3 answers
187 views
I'm doing a rad grid and I'm using the footer with mode as Advanced.
I need to globalize the text that appears in the footer advanced mode.
Someone knows how can I change the text of it?

Thanks.
Leonardo
Top achievements
Rank 1
 answered on 27 Apr 2009
3 answers
119 views
Hi,

my problem is the following.
I allow my customer to change the look of the site's masterpage.
For this I provide (beside others) a "frames.css" this file has a lot of divs with large dimensions (1000x900 and so).
And those divs sometimes have "content" (Background images).
The result - when I use the CSS dropdown in RadEditor it almost becomes unusable due to the fact that it displays previews - 1000px large.

It is a single css file which holds those nasty things. Is there an easy way to tell RadEditor - pleas don't use frames.css.

Regards

Manfred
Tervel
Telerik team
 answered on 27 Apr 2009
4 answers
192 views
Hi

I'm testing RadToolbar on client side with a Combobox that has a treeview inside.

Before this test, I test just a combobox with a treeview inside and it worked ok.

My problem with Radtoolbar is that on first time I select a node, Combox caption shows all my treeview text nodes in a single line. When I select a node for the second time, it works ok.

Ok, here is the code:

<telerik:RadToolBar ID="RadToolBar1" runat="server" Skin="Gray" Width="550px" OnClientButtonClicked="toolbar_execute">
            <CollapseAnimation Duration="200" Type="OutQuint"  />
            <Items>
                 <telerik:RadToolBarButton runat="server" Text="Button_tree" Value="10" >  
                    <ItemTemplate>     
                        <telerik:RadComboBox ID="RadComboBox2" runat="server" Height="140px" Width="215px"
                        ShowToggleImage="True" Skin="Gray" Style="vertical-align: middle;"  OnClientLoad="comboLoad"
                        OnClientDropDownOpened="OnClientDropDownOpenedHandler">
                            <ItemTemplate>
                                    <telerik:RadTreeView runat="server" ID="RadTreeView1" OnClientNodeClicking="nodeClicking"
                                     Skin="WebBlue" Height="140px">
                                        
                                    </telerik:RadTreeView>
                            </ItemTemplate>
                            <Items>
                                <telerik:RadComboBoxItem runat="server" />
                            </Items>
                          <CollapseAnimation Type="None" Duration="200" /><ExpandAnimation Type="None" />
                        </telerik:RadComboBox>
                        
                    </ItemTemplate>
                </telerik:RadToolBarButton>                         
                
            </Items>
        </telerik:RadToolBar>



            <script type="text/javascript">
             
             // I lode Nodes manually
             function addnodes() {
               
               var toolBar = $find("RadToolBar1")
               var comboBox1 = $find('<%=RadToolBar1.FindItemByText("Button_tree").FindControl("RadComboBox2").ClientID %>');
               var tree1 = comboBox1.get_items().getItem(0).findControl("RadTreeView1");
               
               toolBar.trackChanges();
               comboBox1.trackChanges();
               tree1.trackChanges();
               var lbk =-1;
                var local = 0;
               tree1.get_nodes().clear();
               var mnode=new Telerik.Web.UI.RadTreeNode();
               mnode.set_text('(seleccionar)');
               for(var i=0; i<50; i++) {
                   if (lbk != local) {
                        tree1.get_nodes().add(mnode);
                        mnode = new Telerik.Web.UI.RadTreeNode();
                        mnode.set_text('Parent ' + local);
                        lbk = local;
                   }
                         
                   var node = new Telerik.Web.UI.RadTreeNode();
                   node.set_text('item ' + i);
                   mnode.get_nodes().add(node);
                   if ((i==10) || (i==20) || (i==30) || (i==40)) local++;
               }
               if (lbk>=0) {
                   tree1.get_nodes().add(mnode);
                }
               tree1.commitChanges();
               comboBox1.commitChanges();
               toolBar.commitChanges();
            }
            
             
              function comboLoad(sender, eventArgs)
            {
                sender.set_text(sender.get_items().getItem(0).get_value());
            }

            function nodeClicking(sender, args)
            {
                
                var comboBox = $find('<%=RadToolBar1.FindItemByText("Button_tree").FindControl("RadComboBox2").ClientID %>');
                var node = args.get_node()
                if(node.get_level() != "0")  
                {    
                    alert(node.get_text());
                    comboBox.trackChanges();
                    comboBox.get_items().getItem(0).set_value(node.get_text());
                    comboBox.set_text(node.get_text());
                    comboBox.commitChanges();
                }
            }

 
            
            function OnClientDropDownOpenedHandler(sender, eventArgs)
            {
                var tree = sender.get_items().getItem(0).findControl("RadTreeView1");
                var selectedNode = tree.get_selectedNode();
                if (selectedNode)
                {
                    selectedNode.scrollIntoView();
                }
            }
             
             </script>

I'm using version 2008.3.1105.20.

Regards
Yana
Telerik team
 answered on 27 Apr 2009
4 answers
147 views
Hello friends,

  Can anyone answer for this please? I have telerik upload control, First I browse the file and before click the upload button I rename or delete the file what i browse, then I click the upload button and I get the empty file in the file saved folder.How do I check the browse file whether exists or not  before click the upload button.Please help for this.
Veselin Vasilev
Telerik team
 answered on 27 Apr 2009
3 answers
94 views

I'm trying to do a proof of concept... I have 1000 records in a dataset that I'm binding to a GridView... (Which will eventually come in from a RadUpload control and I'll import into a database and then bind to a gridview)...

I am using the RadProgressManager and RadProgressArea to count row by row on the ItemDataBound event of the RadGridView...

What I'm trying to do now, and my question, is how can I get the RadGridView to update on the screen after each row has been added?

After each ItemDataBound update it, using what? I'm trying to see if I can somehow do it with the LoadingPanel control, but not sure. Seems like I need to do some type of Ajax call somewhere... maybe even using jQuery? No idea.

Any thoughts?
Yavor
Telerik team
 answered on 27 Apr 2009
3 answers
186 views
Hello,

I am using the radgrid and radeditor in my page.
When the user click on a row in the grid a particluar column's data should go to the editor and the user can edit the text from the editor based on the permission and then hit on the update button to save the data to the database and then refresh the radgrid. I have put both the controls into an Ajax Manager.

My problem here is.

1)  After editing the text, when I click on update, Editor's SubmitClicked event is firing, but when I give the command radeditor.html I am not getting the latest value from the editor, rather its giving me the initial value which came from the grid column. Is there something I am missing?

2)  Based on the permission, I want to disable the submit button, how do I do that.

Thanks
Viji
Rumen
Telerik team
 answered on 27 Apr 2009
1 answer
105 views
Im currently working with FormatBlock and when I Select a Header style for a texline it automaticly adds another break line under the header. So the source look's like:

<h2 class="baseFont-left1">Header</h2><br />Content text, na na na!!

I want it to look like:

<h2 class="baseFont-left1">Header</h2>Content text, na na na!!




Rumen
Telerik team
 answered on 27 Apr 2009
Narrow your results
Selected tags
Tags
+? more
Top users last month
Tien
Top achievements
Rank 1
Iron
Krasimir
Top achievements
Rank 3
Bronze
Iron
Iron
Cedar
Top achievements
Rank 1
Iron
Emil
Top achievements
Rank 1
Iron
Kyle Watson
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Tien
Top achievements
Rank 1
Iron
Krasimir
Top achievements
Rank 3
Bronze
Iron
Iron
Cedar
Top achievements
Rank 1
Iron
Emil
Top achievements
Rank 1
Iron
Kyle Watson
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?