Telerik Forums
UI for ASP.NET AJAX Forum
2 answers
108 views

We have an application that relies heavily on Telerik controls and noticed with the most recent update (ASP.NET AJAX R3 2016) we have some rendering issues in Chrome. (See attached pictures). Firefox, IE, etc. are all fine. You can see that there is a significant amount of padding between the two checkboxes. 

This is only happening on our development environment and not our live environment. Is there something with this new update that would cause rendering issues in Chrome?

Dustin
Top achievements
Rank 1
 answered on 27 Sep 2016
10 answers
218 views
Hi,

I am using the RadPivotGrid to navigate a OLAP cube on Microsoft Analysis Service. The control connects to the cube through Adomd connection string.
I would like to retrieve the MDX query releated to my navigation. Is it possible?

Thanks in advance.
Trilochan
Top achievements
Rank 1
 answered on 27 Sep 2016
5 answers
184 views

When changing the properties of an image, an icon of a broken paperclip shows next to the height and width, which (if clicked) forces the proportions to be constrained.

Inside RadEditorProvider/App_LocalResources/RadEditor.Dialogs.resx, there is a Name of "SetImageProperties_Constrain" with a value of "Constrain".  However, the properties window is always not-constrained by default... and must be clicked each time.

Our website is hosted on DNN7, which by default contains the Telerik RadEditor.

Any ideas on how to set it to be constrained by default?

Thanks,

-Adam

Rumen
Telerik team
 answered on 27 Sep 2016
1 answer
1.1K+ views

In my web application I use a AsyncUpload to load the picture of each user to their personal page.
I need to limit the dimensions (height and width) of uploaded images.

How can I validate the height and width of the images before they are loaded? Or convert them to the dimensions I want?
I need images have the dimensions 150x100
I have the following code to validate file type and file size of uploaded images.

foreach (UploadedFile file in LogoUpload.UploadedFiles)
    {
        //string filetype = LogoUpload.PostedFile.ContentType;
        string filetype = file.ContentType;
        long filesize = file.ContentLength;
        byte [] input = new byte[filesize - 1];
 
        long maxFileSize = 1024;
 
        if (filesize > maxFileSize)
        {
            base.OnUIValidation("The file is too big.");
            return;
        }
 
        string[] acceptedFileTypes = new string[3];
        acceptedFileTypes[0] = "image/jpg";
        acceptedFileTypes[1] = "image/jpeg";
        acceptedFileTypes[2] = "image/jpeg";
 
        bool acceptFile = false;
 
 
        //should we accept the file?
        for (int i = 0; i <= 2; i++)
        {
            if (filetype == acceptedFileTypes[i])
            {
                //accept the file, yay!
                acceptFile = true;
            }
             }

I have aI have a RadUpload
Rumen
Telerik team
 answered on 27 Sep 2016
1 answer
1.1K+ views

Hi, I have an ascx file that contains a RadNotification and a timer.

<telerik:RadCodeBlock ID="RadCodeBlock1" runat="server">
            <script type="text/javascript">
                function OnClientUpdated(sender, args) {
                    sender.show()
                    $find("<%= RadAjaxManager.GetCurrent(Page).ClientID %>").ajaxRequest("content");
                }
                function UpdateWithoutPopup() {
                    var ajaxManager = $find("<%= RadAjaxManager.GetCurrent(Page).ClientID %>");
                    ajaxManager.ajaxRequest(arguments);
                }
            </script>
</telerik:RadCodeBlock>
 
 
<telerik:RadAjaxManagerProxy ID="AjaxManagerProxy1" runat="server">
    <AjaxSettings>
                <telerik:AjaxSetting AjaxControlID="Timer1">
                    <UpdatedControls>
                        <telerik:AjaxUpdatedControl ControlID="RadNotification1" />
                    </UpdatedControls>
                </telerik:AjaxSetting>
    </AjaxSettings>
</telerik:RadAjaxManagerProxy>
 
 
<asp:Timer ID="Timer1" runat="server" Interval="6000" OnTick="Timer1_Tick" />
 
 
 <telerik:RadNotification RenderMode="Lightweight" id="RadNotification1" runat="server" loadcontenton="EveryShow"
        width="300" height="150" animation="Fade" enableroundedcorners="true" enableshadow="true"
        title="Received messages" offsetx="-20" offsety="-20" onclientupdated="OnClientUpdated"
        titleicon="none" autoclosedelay="5000" Skin="Bootstrap">
        <ContentTemplate>
            <asp:Image ID="Image1" runat="server" CssClass="Max75" />
            <asp:Literal ID="lbl" runat="server"></asp:Literal>
        </ContentTemplate>
    </telerik:RadNotification>

the timer makes the checks and if necessary displays a popup, another calls a function

public void Timer1_Tick(object sender, EventArgs e)
{
        if (Check())
        {
            RadNotification1.Show();
        }
        else
        {
            string script = "UpdateWithoutPopup()";
            ScriptManager.RegisterStartupScript(Page, typeof(Page), "myscript", script, true);
        }
    }

When I show the popup everything works fine when if I call the error function I get the error:

default.aspx:502 Uncaught TypeError: Cannot read property 'ajaxRequest' of null

how do I fix?

thanks in advance

Eyup
Telerik team
 answered on 27 Sep 2016
1 answer
228 views
How do you get the EmptyMessage to show up when using password mode. It looks really funny when the username has the text in there but the password box is empty.
Rumen
Telerik team
 answered on 27 Sep 2016
1 answer
200 views

Hi,

 

I am using AJAX Telerik ASP.NET Radgrid in Batch Edit Mode. I have a template column which has radtextbox or radnumeric text box as edit template.

When I edit the cell and click outside, regular expression validator is not firing, even though range and required validators are working perfectly.

Any specific reason or i am missing something?

Viktor Tachev
Telerik team
 answered on 27 Sep 2016
1 answer
215 views

Hi,
I want to format the date in a "dd.MM.yyyy" I've already tried several options but none that work.

The date is stored in the table as Datetime2.

 

<telerik:RadListView runat="server" ID="rlvEmployes" ClientDataSourceID="rcdsEmployes">
            <LayoutTemplate>
                <div class="RadListView RadListView_Default">
                    <ul class="employes-list" id="itemPlaceholder" runat="server" style="list-style-type:none;">
 
                    </ul>
                </div>
            </LayoutTemplate>
            <ClientSettings>
                <DataBinding>
                    <ItemTemplate>
                        <li>
                            <div class="itemTemplate" data-employe-id="#= ZamestnanecID #">
                                <div class="header">#= Prijmeni # #= Jmeno #</div>
                                <div class="content">
                                    <table>
                                        <tr>
                                            <td>
                                                <span class="label">Aktivní:</span>
                                            </td>
                                            <td>
                                                <input type="checkbox" #= Aktivny ? 'checked="checked"' : '' # />
                                            </td>
                                        </tr>
                                        <tr>
                                            <td>
                                                <span class="label">Datum narození:</span>
                                            </td>
                                            <td>
                                                <span class="info">#= format(DatumNarozeni, "{0:dd/MM/yyyy}") #</span>
                                            </td>
                                            <td>
                                                <span class="label">Číslo OP:</span>
                                            </td>
                                            <td>
                                                <span class="info">#= CisloOP #</span>
                                            </td>
 
                                        </tr>
                                    </table>
                                </div>
                            </div>
                            <div class="editTemplate" style="display:none;">
                                <telerik:RadTextBox runat="server" Text='#= ZamestnanecID #'></telerik:RadTextBox>
                            </div>
                        </li>
                    </ItemTemplate>
                </DataBinding>
            </ClientSettings>
        </telerik:RadListView>

 

Where I make mistakes?

Viktor Tachev
Telerik team
 answered on 27 Sep 2016
1 answer
1.0K+ views

Hi,
I am using a rad org chart.  Basically I want to apply certain CSS styles based on a condition.
I have figured out how to just override a css styles:

.rocToolbar_Metro .rocToolbarButton {   background-color: #32b330 !important;}


But I can’t figure out how to do this conditionally via the code behind, so saying if condition == 1 then apply this:

.rocToolbar_Metro .rocToolbarButton {    background-color: #32b330 !important;}


Else apply this:

.rocToolbar_Metro .rocToolbarButton {    background-color: #25a0da !important;}



I am planning to do this within the NodeDataBound event.  Any suggestions appreciated.
Thanks.

Ivan Danchev
Telerik team
 answered on 27 Sep 2016
1 answer
277 views

I would like to see if it's possible to pass the value from a container.data with rad button in an asp.repeater control.

 

<script type="text/javascript">
function open_windowtemplate_AddSection(sender, args) {
var button = sender.get_id();
alert($(button).commandarguments);
}
</script>

 

<asp:Repeater ID="rpt_Channel" runat="server" OnItemDataBound="rpt_Channel_ItemDataBound">
<ItemTemplate>
<tr>
<td colspan="4" class="MainLineItem">
<div style="float:left;">&#9632; <asp:Label ID="lbl_ChapterName" runat="server" Text='<%#DataBinder.Eval(Container.DataItem, "Chapter")%>'></asp:Label></div>
<div style="float:right">
<asp:ImageButton ID="imgbtn_AddSection" runat="server" AlternateText="Click to add section" ImageUrl="~/Includes/images/green_plus_add.png" Height="20px" CommandName="Add" />
<telerik:RadButton ID="radbutton_AddSection" runat="server" Text="+" CommandArgument='<%Databinder.Eval(Container.DataItem, "Channel_ID") %>'
ButtonType="StandardButton" OnClientClicked='open_windowtemplate_AddSection' AutoPostBack="false">
</telerik:RadButton>

Ianko
Telerik team
 answered on 27 Sep 2016
Narrow your results
Selected tags
Tags
+? more
Top users last month
Rob
Top achievements
Rank 3
Bronze
Iron
Iron
Sergii
Top achievements
Rank 1
Iron
Iron
Dedalus
Top achievements
Rank 1
Iron
Iron
Lan
Top achievements
Rank 1
Iron
Doug
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Top users last month
Rob
Top achievements
Rank 3
Bronze
Iron
Iron
Sergii
Top achievements
Rank 1
Iron
Iron
Dedalus
Top achievements
Rank 1
Iron
Iron
Lan
Top achievements
Rank 1
Iron
Doug
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?