Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
78 views
I have an dropdownlist put above of the grid
inside the grid i have checkbox "GridClientSelectColumn", i want to hide the "GridClientSelectColumn", but, when i choose something in dropdown list
the "GridClientSelectColumn' must appear...is it have any possible way to do
Jayesh Goyani
Top achievements
Rank 2
 answered on 25 Jun 2011
0 answers
73 views
Hi,

I added those things into xml file
<paragraphs>
   <paragraph name="<H1 style='font-size: 14px; font-family: Arial; color:#808080'> Title </H2>" value="<h1 style='font-size: 14px; font-family:Arial;  '> </h1>" />
   <paragraph name="<H2 style='font-size: 12px; font-family: Arial; color:#808080'> Subhead </H2>" value="<h3 style='font-size: 12px; font-family:Arial; '> </h3>" />
   <paragraph name="<H3 style='font-size: 10px;  font-family: Arial; color:#808080'> Text </H3>" value="<h4 style='font-size: 10px; font-family:Arial; '> </h4>" /> 
 </paragraphs>


In Editor only once it show font name for selected text, if i choose second time it not shown the font name in the drop down list.
any solution?

Second Thing,

I need to play video inside of Rad Editor, any suggestions!!!!!


thanks in advance
Vinoth Arun
Top achievements
Rank 2
 asked on 25 Jun 2011
2 answers
145 views
I am using the 2010.3.1510.40 version. When I add an event with recurrence all works fine if I leave it with no end date.
However, if I try to use the "End After 'X' occurrences" option, the rule that is generated does not include anything for that limit and I get an event that recurs forever.
Also, if I try to use the date picker to end a recurrence by a certain date, the rule that is generated has tomorrow's date (no matter what I chose for the end date).

Here is the generated rule for an event that I set with Weekday occurrence, starting on 7/4/2011 and it was supposed to end on 7/9/2011:
DTSTART:20110704T180000Z
DTEND:20110704T200000Z
RRULE:FREQ=DAILY;UNTIL=20110624T050000Z;INTERVAL=1;BYDAY=MO,TU,WE,TH,FR

The "UNTIL" is specified as 6/24/2011 so, needless to say, none of the occurrences ever showed up.

Is there a workaround for this issue?

Thanks.
Chad
Top achievements
Rank 1
 answered on 24 Jun 2011
2 answers
126 views

We have successfully used several Rad Controls in our preexisting AJAX enabled project, but are unable to get spell check working on the RadEditor.

When I click on the spell icon I get the following error:

   Microsoft JScript runtime error: 'null' is null or not an object

The debugger shows the error as occurring in the following function:

// Name:        HTMLEditor.EditPanel.debug.js
// Assembly:    AjaxControlToolkit
// Version:     3.5.50508.0
// FileVersion: 3.5.50508
 _invokingRequest: function(sender, args) {
     if (this._contentPrepared) {
         return;
     }
     var webRequest = args.get_webRequest();
     var body = webRequest.get_body();
     // change body here...
     var reg = new RegExp("([\\?&])(" + this.get_contentElement().name + "=)([^&$]*)([&$])", "g");
     this._prepareContentForPostback(this.get_content());
 >>> body = body.replace(reg, "$1$2" + escape(this.get_contentElement().value) + "$4");  <<<- body is null
     this._contentPrepared = true;
     webRequest.set_body(body);
 },

I followed the directions for adding RadControls for ASP.NET AJAX to an existing application found here: http://www.telerik.com/help/aspnet-ajax/introduction-adding-radcontrols-prometheus-existing-application.html â€¦ and the recommendations for getting started with the editor here: http://www.telerik.com/help/aspnet-ajax/editor-getting-started.html
It should be noted the documentation specified configuration options in Step 9 which did not exist on the Smart Tag Menu (yes, we have the Telerik.Web.UI.dll in the project’s bin folder). Unable to add from the designer, I followed the directions found here: http://www.telerik.com/help/aspnet-ajax/editor-enable-spellcheck.html and manually added the spell check handler to my web.config, resulting in the editor displaying on the UI with a spell check icon on the toolbar.

I also tried substituting in a RadScriptManger in place of the ASP ScriptManger, but that only led to another problem:

Microsoft JScript runtime error: AjaxControlToolkit requires ASP.NET Ajax 4.0 scripts. Ensure the correct version of the scripts are referenced. If you are using an ASP.NET ScriptManager, switch to the AjaxScriptManager in System.Web.Ajax.dll, or use the ToolkitScriptManager in AjaxControlToolkit.dll.

We are developing in VS 2008. Any help is appreciated.

Aaron
Top achievements
Rank 1
 answered on 24 Jun 2011
2 answers
115 views
In years past, when I strictly built WinForms applications I'd use an old product called RoboHelp to build the Windows help files.  It worked fine and was the right tool for the job.

Fast forward to 2011 and I'm in the midst of an ASP.Net 3.5 Intranet application.  I'm now looking to provide some online help for it, which would include:
  1. Context sensitive help from each page in the app.
  2. A general search facility where the user could enter keywords and be shown the applicable help topics.

I could, of course, build this help engine from scratch but I'm thinking there must be a better, easier way.  I'm thus curious whether the great minds at Telerik might have some suggestions, including the use of some of your controls in the ASP.Net AJAX toolkit.

A fairly open question, I know, but am hoping you can give me some good ideas,

Robert
Robert
Top achievements
Rank 1
 answered on 24 Jun 2011
9 answers
117 views
I have a RadGrid that is throwing the error  '_currentFilterTimeoutID' is null or not an object when a value is typed into the filter box.  If I remove FilterDelay, ther error does not occur though neither does the filter.

Below is the radgrid with the RadWindow wrapper.
<telerik:RadWindow ID="GLLookupWindow" runat="server" Behaviors="Close" Width="900" Height="700" OnClientClose="UnhideIframe_OnClientClose">
             <ContentTemplate>
                <asp:Button ID="hiddenButton" OnClientClick="return false;" runat="server" style="display:none" visible="false" />
                <asp:Panel runat="server" ID="pnlGLLookup" Visible="true" TabIndex="-1">
 
                    <telerik:RadGrid AutoGenerateColumns="False" ID="GLLookup" OnItemCommand ="GLLookup_ItemCommand" AllowFilteringByColumn ="true" OnItemCreated="GLLookup_ItemCreated" EnableLinqExpressions="false"
                    DataSourceID="SqlDataSourceGLLookupwindow" AllowSorting="true" runat="server" PagerStyle-AlwaysVisible="true" AllowPaging="true" PageSize ="20">
                        <GroupingSettings CaseSensitive="false" />
                        <MasterTableView DataKeyNames="GCMGRP,GCACCT,GCSACT,GCDEPT,GCDESC"  AutoGenerateColumns="false" AllowFilteringByColumn="True" >
 
                         <PagerStyle Mode="NumericPages" PageButtonCount="10" />
                            <Columns>
                                <telerik:GridBoundColumn SortExpression="GCMGRP" HeaderText="Major" DataField="GCMGRP" UniqueName="GCMGRP" HeaderButtonType="TextButton"
                                    AllowFiltering="true" CurrentFilterFunction="EqualTo" AutoPostBackOnFilter="false" ShowFilterIcon="false" FilterDelay="4000"
                                    HeaderStyle-VerticalAlign="Bottom" HeaderStyle-HorizontalAlign="Center" ItemStyle-HorizontalAlign="Center"/>
 
 
                                <telerik:GridBoundColumn HeaderText="Acct" DataField="GCACCT" UniqueName="GCACCT" AllowFiltering="true"
                                    SortExpression="GCACCT" HeaderStyle-HorizontalAlign="Center" ItemStyle-HorizontalAlign="Center"
                                    HeaderStyle-VerticalAlign="Bottom"
                                    CurrentFilterFunction="EqualTo" AutoPostBackOnFilter="false" ShowFilterIcon="false" FilterDelay="4000" />
                                <telerik:GridBoundColumn HeaderText="Sub" DataField="GCSACT" UniqueName="GCSACT" AllowFiltering="true"
                                    SortExpression="GCSACT" HeaderStyle-HorizontalAlign="Center" ItemStyle-HorizontalAlign="Center"
                                    HeaderStyle-VerticalAlign="Bottom"
                                    CurrentFilterFunction="EqualTo" AutoPostBackOnFilter="false" ShowFilterIcon="false" FilterDelay="4000" />
                                 <telerik:GridBoundColumn HeaderText="Dept/Loc" DataField="GCDEPT" UniqueName="GCDEPT" AllowFiltering="true"
                                    SortExpression="GCDEPT" HeaderStyle-HorizontalAlign="Center" ItemStyle-HorizontalAlign="Center"
                                    HeaderStyle-VerticalAlign="Bottom"
                                    CurrentFilterFunction="EqualTo" AutoPostBackOnFilter="false" ShowFilterIcon="false"  FilterDelay="4000" />
                                 <telerik:GridBoundColumn HeaderText="Description" DataField="GCDESC" UniqueName="GCDESC" AllowFiltering="true"
                                    SortExpression="GCDESC" HeaderStyle-HorizontalAlign="Center" ItemStyle-HorizontalAlign="Center"
                                    HeaderStyle-VerticalAlign="Bottom"
                                    CurrentFilterFunction="Contains" AutoPostBackOnFilter="false" ShowFilterIcon="false" FilterDelay="4000" />
                            </Columns>
                            <ItemStyle Wrap="false" />
                               <PagerStyle Mode="NumericPages" AlwaysVisible="true">
                               </PagerStyle>
                        </MasterTableView>
                        <ClientSettings EnablePostBackOnRowClick="true" >
                        </ClientSettings>
                   </telerik:RadGrid>
                   <asp:Button ID="clrFilters" runat="server" Text="Clear filters" OnClick="clrFilters_Click" />
                </asp:Panel>
             </ContentTemplate>
            </telerik:RadWindow>

AHIA,
LarryR....
Rafy Perez
Top achievements
Rank 1
 answered on 24 Jun 2011
1 answer
44 views
Hi,

I am using the popup form edit mode in the radgrid.  In the edit form I have a user control.  I want to run some javascript when the control is loaded.  I tried using the Page.ClientScript in the Page_Load event of the control itself but that script never gets called.

Where is the appropriate event to hook into?
Genti
Telerik team
 answered on 24 Jun 2011
1 answer
126 views
I have a context menu where I add new nodes. I used this example to create the context menu:http://demos.telerik.com/aspnet-ajax/treeview/examples/functionality/contextmenu/defaultcs.aspx. My issue is that when a user add's a new node I need to capture what the user names the node, so that I can add it to the database. Currently the code uses javascript to set the node as editable on Page Load.

How do I go about capturing the text value the user inputs when adding a new node?

JAVASCRIPT

<script type="text/javascript">
    //<!--
    function onClientContextMenuShowing(sender, args) {
        var treeNode = args.get_node();
        treeNode.set_selected(true);
        //enable/disable menu items
        setMenuItemsState(args.get_menu().get_items(), treeNode);
    }
 
    function onClientContextMenuItemClicking(sender, args) {
        var menuItem = args.get_menuItem();
        var treeNode = args.get_node();
        menuItem.get_menu().hide();
 
        switch (menuItem.get_value()) {
            case "Rename":
                treeNode.startEdit();
                break;
            case "addLocation":
                break;
        }
    }
 
    //this method disables the appropriate context menu items
    function setMenuItemsState(menuItems, treeNode) {
        for (var i = 0; i < menuItems.get_count(); i++) {
            var menuItem = menuItems.getItem(i);
            switch (menuItem.get_value()) {
                case "Rename":
                    formatMenuItem(menuItem, treeNode, 'Rename "{0}"');
                    break;
                case "addLocation":
                    if (treeNode.get_parent() == treeNode.get_treeView()) {
                        menuItem.set_enabled(false);
                    }
                    else {
                        menuItem.set_enabled(true);
                    }
                    break;
            }
        }
        //formats the Text of the menu item
        function formatMenuItem(menuItem, treeNode, formatString) {
            var nodeValue = treeNode.get_value();
            if (nodeValue && nodeValue.indexOf("_Private_") == 0) {
                menuItem.set_enabled(false);
            }
            else {
                menuItem.set_enabled(true);
            }
            var newText = String.format(formatString, extractTitleWithoutMails(treeNode));
            menuItem.set_text(newText);
        }
 
        //checks if the text contains (digit)
        function hasNodeMails(treeNode) {
            return treeNode.get_text().match(/\([\d]+\)/ig);
        }
 
        //removes the brackets with the numbers,e.g. Inbox (30)
        function extractTitleWithoutMails(treeNode) {
            return treeNode.get_text().replace(/\s*\([\d]+\)\s*/ig, "");
        }
    }
 
 
    //-->
      </script>


ASPX

<telerik:RadAjaxLoadingPanel ID="LocationsLoadingPanel" runat="server" Transparency="30" Skin="Vista"></telerik:RadAjaxLoadingPanel>
        <telerik:RadAjaxPanel ID="LocationsPanel" runat="server" LoadingPanelID="LocationsLoadingPanel">
            <telerik:RadTreeView ID="LocationsTreeView" runat="server" EnableDragAndDrop="true"  MultipleSelect="true" EnableDragAndDropBetweenNodes="true"
            AllowNodeEditing="true" OnContextMenuItemClick="LocationsTreeView_ContextMenuItemClick" OnClientContextMenuItemClicking="onClientContextMenuItemClicking"
            OnClientContextMenuShowing="onClientContextMenuShowing" OnNodeEdit="LocationsTreeView_NodeEdit">
             <ContextMenus>
                    <telerik:RadTreeViewContextMenu ID="MainContextMenu" runat="server">
                        <Items>
                            <telerik:RadMenuItem Value="Rename" Text="Rename ..." Enabled="true" ImageUrl="images/icons/edit_48.png"
                                PostBack="false">
                            </telerik:RadMenuItem>
                            <telerik:RadMenuItem IsSeparator="true">
                            </telerik:RadMenuItem>
                            <telerik:RadMenuItem Value="addLocation" Text="Add Location" ImageUrl="images/icons/add_16.png">
                            </telerik:RadMenuItem>                         
                        </Items>
                        <CollapseAnimation Type="none" />
                    </telerik:RadTreeViewContextMenu>
                </ContextMenus>
            </telerik:RadTreeView>
        </telerik:RadAjaxPanel>

C#

protected void LocationsTreeView_ContextMenuItemClick(object sender, RadTreeViewContextMenuEventArgs e)
{
    RadTreeNode clickedNode = e.Node;
 
    switch (e.MenuItem.Value)
    {
        case "addLocation":
            RadTreeNode newLocation = new RadTreeNode(string.Format("Add Location"));
            newLocation.Selected = true;
            newLocation.ImageUrl = clickedNode.ImageUrl;
            clickedNode.Nodes.Add(newLocation);
 
            clickedNode.Expanded = true;
            //update the number in the brackets
            if (Regex.IsMatch(clickedNode.Text, unreadPattern))
                clickedNode.Text = Regex.Replace(clickedNode.Text, unreadPattern, "(" + clickedNode.Nodes.Count.ToString() + ")");
             
            clickedNode.Font.Bold = true;
            //set node's value so we can find it in startNodeInEditMode
            newLocation.Value = newLocation.GetFullPath("/");
            startNodeInEditMode(newLocation.Value);
 
            // Add Location Record to Database
            string ParentID = clickedNode.Value;
            Guid ID = Guid.NewGuid();
            string LocationID = ID.ToString();
            string Name = newLocation.Text;
            LocationsTreeView_AddLocation(ParentID, LocationID, Name);
 
            break;
        case "Delete":
            clickedNode.Remove();
            break;
    }
}
 
private void startNodeInEditMode(string nodeValue)
{
    //find the node by its Value and edit it when page loads
    string js = "Sys.Application.add_load(editNode); function editNode(){ ";
    js += "var tree = $find(\"" + LocationsTreeView.ClientID + "\");";
    js += "var node = tree.findNodeByValue('" + nodeValue + "');";
    js += "if (node) node.startEdit();";
    js += "Sys.Application.remove_load(editNode);};";
 
    RadScriptManager.RegisterStartupScript(Page, Page.GetType(), "nodeEdit", js, true);
}
 
// Used when adding a Location
protected void LocationsTreeView_AddLocation(string ParentID, string LocationID, string Name)
{
    // Set parameters for insert
    locationDataSource.InsertParameters["LocationID"].DefaultValue = LocationID;
    locationDataSource.InsertParameters["ParentID"].DefaultValue = ParentID;
    locationDataSource.InsertParameters["Name"].DefaultValue = Name;
 
   // locationDataSource.Insert();
}
 
// Used when renaming a Location
protected void LocationsTreeView_NodeEdit(object sender, RadTreeNodeEditEventArgs e)
{
    // Update Name on client side
    e.Node.Text = e.Text;
 
    // Update Name in database
    locationDataSource.UpdateParameters["Name"].DefaultValue = e.Text;
    locationDataSource.UpdateParameters["ID"].DefaultValue = e.Node.Value;
 
    locationDataSource.Update();
}

Helen
Telerik team
 answered on 24 Jun 2011
3 answers
103 views
I have a radgrid and because I wanted the expand button to be shown on the right most column part of the grid, i set in mastertableview the attribute ExpandCollapseColumn-Visible="false" and added a new GridTemplateColumn with a button that performs the expand command.

<telerik:GridTemplateColumn  ItemStyle-Width="27px" ItemStyle-Height="46px"  Resizable="false"                 >
            <ItemTemplate>              
                <asp:Button CommandName="ExpandCollapse" runat="server" ID="EC"   CssClass="expandbutton" />              
            </ItemTemplate>
        </telerik:GridTemplateColumn>
Obviously in code behind, I intercept my command and the nestedviewtemplate  in my case is shown correctly on expand. So far so good, expand and collpase work fine, the problem is that on expand,  the columns of my grid (outer grid) loose their size(some become smaller, same become larger than in the all collapsed state).  I tried setting Resizable=false on all GridTemplateColumn, but no result....
Any ideas? Can you please help?

Thank you,
 Marina
Pavlina
Telerik team
 answered on 24 Jun 2011
2 answers
132 views
I have a raddockzone in a page.  Each dock has a usercontrol in its contenttemplate.  If I make a change in the usercontrol, how can I update the parent raddockzone that is in the parent page?
Richard M
Top achievements
Rank 1
 answered on 24 Jun 2011
Narrow your results
Selected tags
Tags
+? more
Top users last month
Jay
Top achievements
Rank 3
Bronze
Iron
Iron
yw
Top achievements
Rank 2
Iron
Iron
Stefan
Top achievements
Rank 2
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Bohdan
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Jay
Top achievements
Rank 3
Bronze
Iron
Iron
yw
Top achievements
Rank 2
Iron
Iron
Stefan
Top achievements
Rank 2
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Bohdan
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?