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

I'm using the scheduler with webservice databinding.

Is it possible to enable the context menu for some appointments, but not for all? If so, how could that be accomplished?

Plamen
Telerik team
 answered on 07 Sep 2015
2 answers
92 views
Here I add custom validation. Here is the code. But it don't give error message.
What should I do for it ??
Rasika
Top achievements
Rank 1
 answered on 07 Sep 2015
2 answers
155 views

RadImageGallery is not  displaying any image. 

<telerik:RadImageGallery ID="rigRMA" runat="server" OnNeedDataSource="rigRMA_NeedDataSource" DataImageField="FILE_PATH" DataThumbnailField="FILE_PATH" DataKeyNames="FILE_PATH" Visible="false"
              DataTitleField="FILE_NAME" Width="647px" Height="480px" LoopItems="true">
              <ThumbnailsAreaSettings ThumbnailWidth="120px" ThumbnailHeight="80px" Height="80px" />
              <ImageAreaSettings Height="400px" />
              </telerik:RadI
protected void rigRMA_NeedDataSource(object sender, ImageGalleryNeedDataSourceEventArgs e)
    {
           rigRMA.DataImageField = "FILE_PATH";
            rigRMA.DataSource = GetView();
}
mageGallery
>

Atif
Top achievements
Rank 1
 answered on 05 Sep 2015
5 answers
729 views

I have a RadGrid that is bound to a SQL database.  On the select statement I generate a column that is not in the table.  "SELECT '-' as [CheckBox] ...".  I then use the ItemDataBound(object sender, Telerik.Web.UI.GridItemEventArgs e) event on the RadGrid to add a column of check boxes (one on each row).  The user selects certain check boxes (specifying a row) and presses a submit button.  How can I read what rows were selected?  

I do not use the information to update the database.  The database is used for management and does not change.  If I can't read the selection is there a different way to do this?  Using a RadGrid is just so nice so I would like to keep using that, but I don't need to bind it to a database.  

 

Thanks,
 Scott

Viktor Tachev
Telerik team
 answered on 04 Sep 2015
3 answers
239 views

Hello,
I've been working with radgrids lately and they are working very inconsistently for me. 
Here is my latest grid:

 [CODE]          <telerik:RadGrid ID="PermissionsGrid" runat="server" AllowPaging="True"              CellSpacing="0" GridLines="None" AutoGenerateColumns="false" OnPageSizeChanged="PermissionsGrid_PageSizeChanged"             OnPageIndexChanged="PermissionsGrid_PageIndexChanged" OnNeedDataSource="PermissionsGrid_OnNeedDataSource"             EnableLinqExpressions="False" Skin="Tabbed" EnableEmbeddedSkins="False" AllowCustomPaging="True"             OnPreRender="PermissionsGrid_PreRender" OnInit="PermissionsGrid_Init">             <ClientSettings>                 <Selecting AllowRowSelect="false"></Selecting>                 <Scrolling AllowScroll="True" UseStaticHeaders="true"></Scrolling>                 <Resizing AllowColumnResize="True" />             </ClientSettings>  [/CODE]

However the pageindexchanged event was not fiiring, therefore I added rebind on postback, which then fired onneeddatasource which made the page index changed event fire only then, which was very weird, as well it only worked if i did databind on the radgrid once again (rebind was not working).
Now I am having problem with PageSizeChanged event, was not inteding to put it, but it is not working for me at all. However this time it's neither fiiring even after rebinding on postback and I cant seem to find why.  

Init and prerender are only for nestedViewTemplate purposes, therefore there is nothing interesting there.

I am using one of the newer telerik controls (2015.2.623.35)

As well as the pager dissapears even if I set pager style on mastertableview as always visible, on in the grid itself and even in the code, it does not intend to stay even with all this code on its back. I am out of ideas and I need help with this.

Viktor Tachev
Telerik team
 answered on 04 Sep 2015
1 answer
99 views

I love the look of the mobile version of radgrid paging so I want to use it regardless if the client is on a desktop. I don't want to use the "auto" render mode.

In the header I have the following Javascript which works correctly if RenderMode=Mobile is NOT set:

 

<script type="text/javascript">
 
        function CheckAll(checkAllBox, checkboxName, allcheckboxName) {
 
            //var frm = document.form1;
            var frm = document.getElementById('form1');
            var ChkState = checkAllBox.checked;
 
            for (i = 0; i < frm.length; i++) {
                e = frm.elements[i];
                if (e.type == 'checkbox' && e.name.indexOf(checkboxName) != -1)
                    e.checked = ChkState;
            }
 
        }
 
     </script>

 

A simple radgrid I created on a new webform clean of any of my own javascript and css:

<telerik:RadScriptManager ID="RadScriptManager1" Runat="server"></telerik:RadScriptManager>
 
    <telerik:RadGrid BorderStyle="None" Width="100%"  ID="dgrTestGrid"   runat="server" AllowPaging="True" AllowSorting="True"  AutoGenerateColumns="False"  GridLines="None" PageSize="20" RenderMode="Mobile"  >
                       <pagerStyle Mode="NextPrevNumericAndAdvanced"  />
                        
                       <MastertableView EnableNoRecordsTemplate="True" >
                            <Columns>      
                                
                <telerik:GridTemplateColumn   UniqueName="TemplateColumn">
                    
                       <ItemStyle HorizontalAlign="Center" CssClass="TableBodyLight"></ItemStyle>
                       <HeaderTemplate>
                            <asp:CheckBox ID="ckbSelectAll" runat="server"  />
                       </HeaderTemplate>
 
                       <ItemTemplate>
                           <asp:CheckBox ID="ckbSelect" runat="server" />
                            
                       </ItemTemplate>
               </telerik:GridTemplateColumn>
 
             
            
                           </Columns>
 
                             <NoRecordsTemplate>
                               <div class="NoRecords">You have no Records.</div>
                            </NoRecordsTemplate>
 
                        </MastertableView>
   

 

                   </telerik:RadGrid>

 

 Bind your own data to this and you'll see what I mean. You can't check the checkbox in the header (you can but it doesn't toggle the checkboxes in the rows).

 Any suggestions on how to set the pager to be mobile and have the check all functionality (without ajax.. I want it to be client side) other than just recreating the look with a custom pager or going with a simple ASP datagrid (which defeats the purpose of me using Radcontrols in the first place).

 

 

 

 

Viktor Tachev
Telerik team
 answered on 04 Sep 2015
3 answers
88 views

Hello

As the classic telerik controls are no more supported by telerik I try my luck here...

The problem occurs with a user control that dynamically creates a dialog
using some RadComboBox (version V2.8.8) controls. The problem occurs only when there are
items with umlaut (eg. 'Enhält') in the drop down box.

Is this issue known and is there a workaround for this? As for now we suggest to our customer to use another browser.

Here you find a working project demonstrating the issue with IE 11: http://www.filedropper.com/webcontrols-manualtests
There is also video and a word document showing the result in IE (not working) and firefox (working as expected).

Changing the code to use the latest telerik controls would be also an option, but I didn't manage to convert the code.

Hope someone can help!

Regards,
Tonino.

Tonino
Top achievements
Rank 1
 answered on 04 Sep 2015
1 answer
127 views

Hi!

I'm using multiple RadComboBoxes that are filled by a web service like this:

1.<telerik:RadComboBox runat="server" ID="Value" Width="300px" EnableLoadOnDemand="true" OnClientItemsRequesting="LookupItemRequesting" OnItemsRequested="Value_OnItemsRequested" AutoPostBack="False">
2.  <WebServiceSettings Path="/Handlers/IdmpService.asmx" Method="LoadDropDownValues" UseHttpGet="true"></WebServiceSettings>
3.</telerik:RadComboBox>

The method to fill the combobox looks like this:

01.[WebMethod(true)]
02.[ScriptMethod(UseHttpGet = true)]
03.public RadComboBoxData LoadDropDownValues(RadComboBoxContext context)
04.{
05.  var res = new RadComboBoxData();
06.  var itemType = context["ItemType"].AsString();
07.  var valueProperty = context["ValueProperty"].AsString();
08.  ...
09.  var result = new List<RadComboBoxItemData>();
10.  try
11.  {
12.    ...
13.    foreach (Dictionary<string, object> item in items)
14.    {
15.      // process items...
16.      result.Add(new RadComboBoxItemData { Value = "some integer id", Text = string.Join(", ", string.Format(displayFormat, values.ToArray())) });
17.    }
18.  }
19.  catch (Exception ex)
20.  {
21.    result = new List<RadComboBoxItemData> { new RadComboBoxItemData { Value = "", Text = ex.Message } };
22.  }
23.  res.Items = result.ToArray();
24.  return res;
25.}

Together with quite a few other Telerik controls this is a form used to view/edit data, so I need to set a specific value for thie ComboBox. How can I assign a value to the ComboBox to make sure that when I save the whole data, I can read the correct value from the ComboBox?

Thanks!

 

Nencho
Telerik team
 answered on 04 Sep 2015
9 answers
203 views
Hey,

I have a problem with my radmap. In fact, when i use my MasterPage, my radmap becomes white (i havent Layers...)

Look my code :

DEFAULT.ASPX
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Default.aspx.cs" MasterPageFile="~/SITE CG/CG71/MasterPage.Master" Inherits="Portail_Eau.Default" %>
 
<%@ Register Assembly="Telerik.Web.UI" Namespace="Telerik.Web.UI" TagPrefix="telerik" %>
<%@ Register Src="~/UserControl/UserImpInfo.ascx" TagPrefix="uc1" TagName="UserImpInfo" %>
<%@ Register Src="~/UserControl/UserCaracStation.ascx" TagPrefix="uc1" TagName="UserCaracStation" %>
<%@ Register Src="~/UserControl/UserFonctioStation.ascx" TagPrefix="uc1" TagName="UserFonctioStation" %>
<%@ Register Src="~/UserControl/UserGestionDoc.ascx" TagPrefix="uc1" TagName="UserGestionDoc" %>
<%@ Register Src="~/UserControl/UserERROR.ascx" TagPrefix="uc1" TagName="UserERROR" %>
 
 
<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
 
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
 
    <script src="Content/Scripts.js"></script>
    <link href="Content/DefaultStyles.css" rel="stylesheet" />
 
    <form id="form1" runat="server">
 
        <telerik:RadScriptManager ID="RadScriptManager1" runat="server">
            <Scripts>
                <asp:ScriptReference Assembly="Telerik.Web.UI" Name="Telerik.Web.UI.Common.Core.js"></asp:ScriptReference>
                <asp:ScriptReference Assembly="Telerik.Web.UI" Name="Telerik.Web.UI.Common.jQuery.js"></asp:ScriptReference>
                <asp:ScriptReference Assembly="Telerik.Web.UI" Name="Telerik.Web.UI.Common.jQueryInclude.js"></asp:ScriptReference>
            </Scripts>
        </telerik:RadScriptManager>
 
        
            <telerik:RadMap ID="RadMap1" runat="server" MinZoom="9" OnItemDataBound="RadMap1_ItemDataBound" CssClass="MyRadMap">
                <DataBindings>
                    <MarkerBinding DataShapeField="Shape" DataTitleField="nomStation" DataLocationLatitudeField="latitude" DataLocationLongitudeField="longitude" />
                </DataBindings>
                <LayersCollection>
                    <telerik:MapLayer Subdomains="a,b,c" Type="Tile" UrlTemplate="http://#= subdomain #.tile.thunderforest.com/outdoors/#= zoom #/#= x #/#= y #.png"></telerik:MapLayer>
                </LayersCollection>
            </telerik:RadMap>
 
             
    </form>
 
</asp:Content>


And my MasterPage :
<%@ Master Language="C#" AutoEventWireup="true" CodeBehind="MasterPage.master.cs" Inherits="Portail_Eau.SITE_CG.CG71.MasterPage" %>
 
<!doctype html>
 
<html lang="fr" class="no-js">
<head runat="server">
 
    <title>Département de Saône-et-Loire-Très haut débit</title>
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
    <link href="../../SITE CG/CG71/styles/style.css" rel="stylesheet" type="text/css" />
     
    <link rel="icon" type="image/gif" href="http://www.cg71.fr/typo3conf/ext/e_tca_extented/res/cg71/images/favicon.ico" />
    <link href="../../SITE CG/CG71/typo3conf/ext/e_googlemap/pi1/infobulle.css" rel="stylesheet" type="text/css" />
 
</head>
<body>
   
        <asp:ContentPlaceHolder ID="ContentPlaceHolder1" runat="server">
         
        </asp:ContentPlaceHolder>
    
 
</body>
 
</html>



This is my result :

http://puu.sh/f5OX7/27239a7d9a.jpg


Hum, wierd !
Ianko
Telerik team
 answered on 04 Sep 2015
9 answers
527 views
Hi,
I added some custom tools in my radEditor and I open the RadWindow with this code :

Telerik.Web.UI.Editor.CommandList["InsertDoc"] = function (commandName, editor, args)
    {
        var myCallbackFunction = function (sender, args)
        {
            alert("Hello World");
        }    
        
        editor.showExternalDialog
        (
            '/Test.aspx',
            {},
            950,
            700,
            myCallbackFunction,
            null,
            'Insert Document',
            true,
            Telerik.Web.UI.WindowBehaviors.Close + Telerik.Web.UI.WindowBehaviors.Move,
            false,
            true
        );
    };

 It works fine but now, I would like to maximize the RadWindow like with this code

var manager = $find("<%= RadWindowManager1.ClientID %>");
var oWin = manager.open("Test.aspx", "RadWindow1");
oWin.maximize();

How can I do that ??

Thanks.
Fernando
Top achievements
Rank 2
 answered on 04 Sep 2015
Narrow your results
Selected tags
Tags
+? more
Top users last month
Will
Top achievements
Rank 2
Iron
Motti
Top achievements
Rank 1
Iron
Hester
Top achievements
Rank 1
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Thomas
Top achievements
Rank 2
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Will
Top achievements
Rank 2
Iron
Motti
Top achievements
Rank 1
Iron
Hester
Top achievements
Rank 1
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Thomas
Top achievements
Rank 2
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?