Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
98 views
I have a Modal ToolTip with ShowEven and HideEvent both set to FromCode.  The ToolTip displays a panel that contains a RadGrid and two buttons.  The Grid is set to allow column filtering.

When I run the page and display the ToolTip it works fine.  However, if I apply a filter, that causes a PostBack which "closes" the ToolTip. I think from other posts I have read that I need to either reshow the ToolTip or "ajaxify" the grid so that the postback is only a partial. 

What's the best approach?  If I decide to reshow the ToolTip, how do I determine that it was supposed to be open?  If I decide to ajaxify the interaction, what settings?  I tried setting the Grid as the Target and the ToolTip as the Updated control but that didn't help.

Steve
Marin Bratanov
Telerik team
 answered on 11 Feb 2013
1 answer
164 views
I have a ToolTip that is set to Modal with the ShowEvent and HideEvent both set to FromCode.  Is there a way to determine if the ToolTip is showing in the CodeBehind?
Marin Bratanov
Telerik team
 answered on 11 Feb 2013
1 answer
129 views
Hello,

I have a project that basically looks like this:
  • Default.aspx - the page from which all activity begins
  • Vendors.aspx - a page displayed in a RadWindow opened from Default.aspx
  • VendorDetails.aspx - a page displayed in a RadWindow opened from Vendors.aspx which is used to add/edit a vendor.

When I open for the first time the Vendors window from Default.aspx and do some add/edit operation using the VendorDetails window (close/open several times), there is no problem. After I close the Vendors window, then open it again from Default.aspx, then open the VendorDetails, the first time I close the VendorDetails window, I get an error: Microsoft JScript runtime error: Can't execute code from a freed script.

I'm displaying the VendorDetails using Javascript:

var parentRadWindowManager = GetRadWindow().BrowserWindow.GetRadWindowManager();
var oWnd2 = parentRadWindowManager.open("VendorDetails.aspx?VendorID=0", "rwAddNewVendor");
   window.setTimeout(function () {
      oWnd2.set_title("Add new vendor");
      oWnd2.setActive(true);
      oWnd2.set_modal(true);
      oWnd2.setSize(800, 420);
      oWnd2.set_behaviors(Telerik.Web.UI.WindowBehaviors.Move + Telerik.Web.UI.WindowBehaviors.Close);
      oWnd2.set_visibleStatusbar(false);
      oWnd2.set_showContentDuringLoad(false);
      oWnd2.center();
      oWnd2.add_close(RefreshGrids);
   }, 0);
return false;

I suspect the problem is in the VendorDetails.aspx RadWindow. This window contains the following Javascript:
<telerik:RadCodeBlock ID="RadCodeBlock1" runat="server">
   <script type="text/javascript">
       function GetRadWindow() {
           var oWindow = null; if (window.radWindow)
           oWindow = window.radWindow; else if (window.frameElement.radWindow)
           oWindow = window.frameElement.radWindow; return oWindow;
       }
 
       function windowClose() {
           var oWindow = GetRadWindow();
           oWindow.showConfirm = false;
           oWindow.argument = null;
           oWindow.close();
           return false;
       }
   </script>
</telerik:RadCodeBlock>
Marin Bratanov
Telerik team
 answered on 11 Feb 2013
1 answer
178 views
I have migrated a web application from .net framework 2.0 to 4.0 and I am using Telerik.Web.UI dll with version (2009.1.311.35).In one aspx page 
when I check the asp:checkbox with AutoPostback="True", I am getting Javascript error Sys.WebForms.PageRequestManager.getInstance()._destroyTree(_3d);) and page do not get postback, I have goggled it and find some blog post for it.

http://www.toplinestrategies.com/dotneters/random-error-message/random-error-message-sys-webforms-pagerequestmanager-getinstance-_destroytreeb/?lang=en
http://www.telerik.com/community/forums/aspnet-ajax/combobox/radcombobox-vs2010-bug.aspx

I do not have RadAjaxManager either on the page or master page which it's use ( But it's there in other pages of application), but I do have the RadComboBox on the same page.
Can you please tell me is there any workaround available for the version of telerik we are using??
we have already upgraded to the new version,but for intermediate release we want to ship with old version of telerik only.

Please suggest.
 

Maria Ilieva
Telerik team
 answered on 11 Feb 2013
7 answers
1.3K+ views
Hi,

I have been unsuccessful in obtaining a reference to the RadWindowManager via the GetRadWindowManager or the $find() calls.

$find returns null and GetRadWindowManager returns undefined.

Any help would be greatly appreciated.

Thanks in advance,
Robert


<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default.aspx.cs" Inherits="_Default" %> 
<%@ Register Assembly="Telerik.Web.UI" Namespace="Telerik.Web.UI" TagPrefix="telerik" %> 
 
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> 
<html xmlns="http://www.w3.org/1999/xhtml"
<head runat="server"
    <title>Untitled Page</title> 
     
    <script language="javascript" type="text/javascript">   
           
            function OpenWindow(name) 
            { 
                alert(name); 
                 
                var mgr =  $find('RadWindowManager1'); // GetRadWindowManager(); 
                 
                var wnd = mgr.open("http://www.google.com", null);          
                 
                return false; 
            }   
               
    </script> 
     
       
</head> 
<body> 
    <form id="form1" runat="server"
        <asp:ScriptManager ID="ScriptManager1" runat="server" /> 
        <telerik:RadWindowManager ID="RadWindowManager1" runat="server"
            <Windows> 
                <telerik:RadWindow ID="RadWindow1" runat="server"
                </telerik:RadWindow> 
            </Windows> 
        </telerik:RadWindowManager> 
         
        
        <asp:Button ID="Button1" runat="server" Text="Button" OnClick="Button1_Click" />       
        <asp:Label ID="InjectScript" runat="server" Text=""></asp:Label> 
 
    </form> 
</body> 
</html> 
 

protected void Button1_Click(object sender, EventArgs e) 
    { 
        InjectScript.Text = "<script type='text/javascript'>OpenWindow('RadWindowServicePopup')</script>"
    } 


Jasfer
Top achievements
Rank 1
 answered on 11 Feb 2013
4 answers
160 views

Hi, I can't seem to get my sort arrow icons to appear for a GridTemplateColumn. There isn't even an "X" appearing as if it didn't find the file. Is there something special I need to do?

<telerik:RadGrid  ID="grdSearchResult" EnableEmbeddedSkins="false" ImagesPath="~/Images" runat="server" AllowSorting="true" AutoGenerateColumns="false" OnSortCommand="grdSearchResult_SortCommand" OnItemDataBound="grdSearchResult_OnItemDataBound">

<telerik:GridTemplateColumn ShowSortIcon="true" SortAscImageUrl="~/Images/down.png" SortDescImageUrl="~/Images/up.png">

....

Is there another setting or something I need to do in the OnSortCommand event?  Thanks, Dave

Shinu
Top achievements
Rank 2
 answered on 11 Feb 2013
6 answers
144 views
I have this error

The Visible property cannot be set on Web Part 'g_XXX'. It can only be set on a standalone Web Part.

It gives error when add document to list webpart which is in radtabstrip's tab. Or when i want to edit page.
Everybody says not use "webpart.visible", use "webpart.hidden" but i did not do anything on code. Maybe radtabstrip doing this?
What is the problem and how can i fix this?
I have a pagelayout like this,

<asp:Content ContentPlaceholderID="PlaceHolderPageTitle" runat="server">
    <SharePointWebControls:FieldValue id="PageTitle" FieldName="Title" runat="server"/>
</asp:Content>
<asp:Content ContentPlaceholderID="PlaceHolderMain" runat="server">
    <WebPartPages:SPProxyWebPartManager runat="server" id="spproxywebpartmanager"></WebPartPages:SPProxyWebPartManager>
        <WebPartPages:WebPartZone id="g_ProjectWP" runat="server" title="Zone 1"><ZoneTemplate></ZoneTemplate></WebPartPages:WebPartZone>
     
        <telerik:RadTabStrip ID="RadTabStrip1" runat="server" SelectedIndex="0" ReorderTabsOnSelect="True"
                MultiPageID="RadMultiPage1" ShowBaseLine="true" CausesValidation="False">
                <Tabs>
                    <telerik:RadTab runat="server" Owner="RadTabStrip1" Selected="True" Text="Proje Sayfası">
                    </telerik:RadTab>
                    <telerik:RadTab runat="server" Owner="RadTabStrip1" Text="Title1">
                    </telerik:RadTab>
                    <telerik:RadTab runat="server" Owner="RadTabStrip1" Text="Title2">
                    </telerik:RadTab>
                    <telerik:RadTab runat="server" Owner="RadTabStrip1" Text="Title3">
                    </telerik:RadTab>
                    <telerik:RadTab runat="server" Owner="RadTabStrip1" Text="Title4">
                    </telerik:RadTab>
                </Tabs>
            </telerik:RadTabStrip>
            <telerik:RadMultiPage ID="RadMultiPage1" runat="server">
                <telerik:RadPageView ID="RadPageView1" runat="server" Selected="true">
                <div class="Left">
                    <WebPartPages:WebPartZone id="g_ProjeLeft" runat="server" title="Zone 2"><ZoneTemplate></ZoneTemplate></WebPartPages:WebPartZone>
                </div>
                <div class="Right">
                    <WebPartPages:WebPartZone id="g_ProjeRight" runat="server" title="Zone 3"><ZoneTemplate></ZoneTemplate></WebPartPages:WebPartZone>
                </div>
                </telerik:RadPageView>
                <telerik:RadPageView ID="RadPageView2" runat="server">
                <WebPartPages:WebPartZone id="g_Title1WP" runat="server" title="Zone 4"><ZoneTemplate></ZoneTemplate></WebPartPages:WebPartZone>
                </telerik:RadPageView>
                <telerik:RadPageView ID="RadPageView3" runat="server">
                <WebPartPages:WebPartZone id="g_Title2WP" runat="server" title="Zone 5"><ZoneTemplate></ZoneTemplate></WebPartPages:WebPartZone>
                </telerik:RadPageView>
                <telerik:RadPageView ID="RadPageView4" runat="server">
                <WebPartPages:WebPartZone id="g_Title3" runat="server" title="Zone 6"><ZoneTemplate></ZoneTemplate></WebPartPages:WebPartZone>
                </telerik:RadPageView>
                <telerik:RadPageView ID="RadPageView5" runat="server">
                 
                <WebPartPages:WebPartZone id="g_Title4" runat="server" title="Zone 7"><ZoneTemplate></ZoneTemplate></WebPartPages:WebPartZone></telerik:RadPageView>
    </telerik:RadMultiPage>
    </asp:Content>


Duygu
Top achievements
Rank 1
 answered on 11 Feb 2013
3 answers
133 views
I have a strange problem!
When I upload via the windows explorer upload facility on 4 out 60 directories it does not upload the files.

The directories are all created via Directory.Create();
The 4 directories that are in question are not the longest file names, but all have similar names, they are:
Safari Bella Leopard
Safari Bella Zebra
Safari Tall Leopard
Safari Tall Zebra


yet the file names:
Safari Short Zebra Collection
Safari Short Leopard Collection

work fine and more interestingly I can create the dummy file "blah.txt" (as you can see in the code below) in the directories that are having the issues.

Below is the code I use
<telerik:RadFileExplorer ID="RadFileExplorer1" Runat="server"
                            Width="600px" EnableAsyncUpload="True"
        EnableCreateNewFolder="False" ExplorerMode="Thumbnails"
                            VisibleControls="Toolbar, ContextMenus, FileList"
        AvailableFileListControls="Thumbnails" Skin="Office2010Blue">
                            <Configuration EnableAsyncUpload="True" SearchPatterns="*.*" />
                        </telerik:RadFileExplorer>

string physicalPath = Directory.GetParent(Server.MapPath("").ToString()).ToString() + "\\Product Images\\" + Request.QueryString["id"].ToString();
if (!Directory.Exists(physicalPath))
{
try
{
Directory.CreateDirectory(physicalPath);
}
catch (Exception ex) { RadAjaxManager1.Alert(Misc.CleanForDatabase(ex.Message)); }
}
try
{
File.CreateText(physicalPath + "/blah.txt");
}
catch (Exception ex1) { RadAjaxManager1.Alert(ex1.Message); }
string[] relativePath = new string[] { "~/Product Images/" + Request.QueryString["id"].ToString() + "/" };
RadFileExplorer1.Configuration.UploadPaths = relativePath;
RadFileExplorer1.Configuration.DeletePaths = relativePath;
RadFileExplorer1.Configuration.ViewPaths = relativePath;
RadFileExplorer1.Configuration.MaxUploadFileSize = 10485760;

I hope someone has some ideas on this... I have exhausted all of mine ((

Thanks in advance :)
Vessy
Telerik team
 answered on 11 Feb 2013
5 answers
447 views
hi,

i need to edit the multiple rows editing at the final when i click save i able to find which row is modified based on this only modified rows will be updated in data base
for ex: http://demos.kendoui.com/web/grid/editing.html

I need this type of grid it is possible with telerik

Thanks & Regards,
M.Koteswara Rao
Princy
Top achievements
Rank 2
 answered on 11 Feb 2013
6 answers
664 views
I am having an issue trying to set a default filter.
this is my grid if the user is of a certine type I want to filter the first grid and then not allow them to change the client.

 <telerik:RadGrid ID="RadGrid1" AllowFilteringByColumn="true" runat="server" GridLines="None" 
                        AllowPaging="true" AllowCustomPaging="true" AllowSorting="true" PageSize="5" OnPreRender="RadGrid1_PreRender" OnItemCreated="RadGrid1_ItemCreated" 
                        Skin="Office2007" EnableViewState="false" PagerStyle-AlwaysVisible="true">  
                        <ClientSettings> 
                            <ClientEvents OnCommand="RadGrid1_Command" OnHierarchyExpanding="RadGrid1_HierarchyExpanding" 
                                OnHierarchyCollapsing="RadGrid1_HierarchyCollapsing" /> 
                        </ClientSettings> 
                        <MasterTableView HierarchyLoadMode="Client" ClientDataKeyNames="ClientID" PagerStyle-AlwaysVisible="true">  
                            <AlternatingItemStyle BackColor="#EEEEEE"></AlternatingItemStyle> 
                            <RowIndicatorColumn> 
                                <HeaderStyle Width="10px"></HeaderStyle> 
                            </RowIndicatorColumn> 
                            <ExpandCollapseColumn Visible="True">  
                                <HeaderStyle Width="10px"></HeaderStyle> 
                            </ExpandCollapseColumn> 
                            <Columns>                                 
                                <telerik:GridBoundColumn DataField="ClientID" SortExpression="ClientID"/>  
                                <telerik:GridBoundColumn SortExpression="ClientName" DataField="ClientName" HeaderText="Client Name" HeaderStyle-Width="100%" /> 
                            </Columns> 
                            <NestedViewTemplate> 
                                <telerik:RadGrid ID="RadGrid2" AllowFilteringByColumn="true" Skin="Office2007" runat="server" 
                                    GridLines="None" AllowPaging="true" AllowSorting="true" PageSize="10" EnableViewState="false">  
                                    <AlternatingItemStyle BackColor="#EEEEEE"></AlternatingItemStyle> 
                                    <ClientSettings> 
                                        <ClientEvents OnCommand="RadGrid2_Command" /> 
                                    </ClientSettings> 
                                    <MasterTableView ClientDataKeyNames="TradeConflictID, AdvisorBlotterID, APTransactionID">  
                                        <Columns> 
                                            <telerik:GridBoundColumn SortExpression="AccountName" DataField="AccountName" HeaderText="Account Name" /> 
                                            <telerik:GridBoundColumn SortExpression="TradeDate" DataField="TradeDate" HeaderText="Trade Date" 
                                                DataType="System.DateTime" DataFormatString="{0:MM/dd/yyyy}" /> 
                                            <telerik:GridBoundColumn SortExpression="ABTransType" DataField="ABTransType" HeaderText="Transaction" /> 
                                            <telerik:GridBoundColumn SortExpression="Ticker" DataField="Ticker" HeaderText="Ticker" /> 
                                            <telerik:GridBoundColumn SortExpression="AccessPerson" DataField="AccessPerson" HeaderText="Access Person" /> 
                                            <telerik:GridBoundColumn SortExpression="APTradeDate" DataField="APTradeDate" HeaderText="Trade Date" 
                                                DataType="System.DateTime" DataFormatString="{0:MM/dd/yyyy}" /> 
                                            <telerik:GridBoundColumn SortExpression="APTransType" DataField="APTransType" HeaderText="Transaction" /> 
                                            <telerik:GridBoundColumn SortExpression="APTicker" DataField="Ticker" HeaderText="Ticker" />                                                         
                                            <telerik:GridCheckBoxColumn SortExpression ="Complete" DataField="Complete" HeaderText="Complete"  DataType="System.Boolean" />                                           
                                            <telerik:GridBoundColumn DataField="View" AllowFiltering="false" HeaderText="" AllowSorting="false" 
                                                UniqueName="View" Visible="true">  
                                            </telerik:GridBoundColumn> 
                                            <telerik:GridBoundColumn DataField="Edit" AllowFiltering="false" HeaderText="" AllowSorting="false" 
                                                UniqueName="Edit" Visible="true">  
                                            </telerik:GridBoundColumn> 
                                        </Columns> 
                                    </MasterTableView> 
                                    <PagerStyle AlwaysVisible="true" /> 
                                </telerik:RadGrid> 
                            </NestedViewTemplate> 
                        </MasterTableView> 
                        <PagerStyle AlwaysVisible="true" /> 
                        <FilterMenu EnableTheming="True">  
                            <CollapseAnimation Type="OutQuint" Duration="200"></CollapseAnimation> 
                        </FilterMenu> 
                    </telerik:RadGrid> 

this is the code behind
 protected void RadGrid1_ItemCreated(object sender, Telerik.Web.UI.GridItemEventArgs e)  
        {  
 
            if (e.Item is GridFilteringItem)  
            {  
                if (Session["AdvisorClientID"] != null)  
                {  
                    GridFilteringItem filterItem = (GridFilteringItem)e.Item;  
                    filterItem.Visible = false;  
                }  
            }  
        }  
        protected void RadGrid1_PreRender(object sender, System.EventArgs e)  
        {  
            if (!Page.IsPostBack)  
            {  
 
                if (Session["AdvisorClientID"] != null)  
                {  
                    RadGrid1.MasterTableView.FilterExpression = "([ClientID] = '" + Session["AdvisorClientID"].ToString() + "\' ) ";  
                    GridColumn column = RadGrid1.MasterTableView.GetColumnSafe("ClientID");  
                    column.CurrentFilterFunction = GridKnownFunction.EqualTo;    
 
                    RadGrid1.MasterTableView.Rebind();  
                }  
            }  
        }  

WHen I run the app as a user that should be filtered I get and error  Expression expected on RadGrid1.MasterTable.Rebind().

what have I missed
Nicolaï
Top achievements
Rank 2
 answered on 11 Feb 2013
Narrow your results
Selected tags
Tags
+? more
Top users last month
Cynthia
Top achievements
Rank 1
Iron
Toby
Top achievements
Rank 3
Iron
Iron
Iron
Danielle
Top achievements
Rank 1
Iron
Iron
Iron
Joel
Top achievements
Rank 3
Bronze
Bronze
Iron
yw
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Cynthia
Top achievements
Rank 1
Iron
Toby
Top achievements
Rank 3
Iron
Iron
Iron
Danielle
Top achievements
Rank 1
Iron
Iron
Iron
Joel
Top achievements
Rank 3
Bronze
Bronze
Iron
yw
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?