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

  Any one here have any idea what barcode format this is?
Makaveil
Top achievements
Rank 1
 answered on 13 Dec 2013
10 answers
356 views
Hi,

Assembly Version: 2010.2.826.35

1. I want to restrict user to upload max 5 files.That works fine if single file selected 5 times which makes file selection control hidden.
But in MultipleFileSelection scenario it allows user to select any number of files ignoring  MaxFileInputCount = 5.How to handle this?


<
telerik:RadAsyncUpload ID="radUpload" runat="server" MultipleFileSelection="Automatic" AllowedFileExtensions=".pdf" MaxFileInputsCount="5"  Localization-Select="Browse" Localization-Remove = "Delete Document" ReadOnlyFileInputs="true" OnClientValidationFailed="validationFailed" TemporaryFileExpiration="5" OnClientFileSelected="fileSelected" OnClientDeleting="fileDelete" OnClientFileUploaded ="fileUploaded" ></telerik:RadAsyncUpload>


2.Other application requirement is to disable Upload control for file selection/deletion while file upload is in progress. Can any one tell  how to achieve that?


Thanks
Deepak Dhirhe
Kalpesh
Top achievements
Rank 1
 answered on 13 Dec 2013
1 answer
113 views
Can I disable a client validation of RadInputManager in Javascript ? as I can disable a Required Field Validator in JS
Kostadin
Telerik team
 answered on 13 Dec 2013
0 answers
85 views
Hi All,

I am using telerik (version 2012.2.724.35) .In my page i have an radupload and an next button. I want to make it accessible through Keys To achecive this i added Below code on OnClientAdded event of Radupload control But it didn't work Properly.

 

function

 

keyboardSupport(sender, args) {

 

 

var $fileInput = $(args._fileInputField);

 

 

var $fakeInput = $fileInput.nextAll("input[class='ruFakeInput']");

 

 

var $selectButton = $fileInput.nextAll("input[class='ruButton ruBrowse']");

 

$selectButton.attr(

'aria-required', 'true');

 

$fileInput.attr(

'aria-required', 'true');

 

$(

'label[for$="_DocumentFileUploadfile0"]').text('<%=GetLocalResourceObject("UploadDocumentLabelResource.Text") %>');

 

$fakeInput.attr(

"tabindex", "-1");

 

$selectButton.attr(

"tabindex", "-1");

 

$fileInput.focus(

function(e) {

 

$selectButton.css(

"border", "1px dotted");

 

});

$fileInput.blur(

function(e) {

 

$selectButton.css(

"border", "0px");

 

});

 

if (navigator.userAgent.indexOf("MSIE") != -1) {

 

$fileInput.keydown(

function(e) {

 

 

if (e.keyCode == Sys.UI.Key.space) {

 

$fileInput.click();

}

 

if (e.keyCode == Sys.UI.Key.enter) {

 

e.preventDefault();

}

 

if (e.keyCode == Sys.UI.Key.tab && e.shiftKey == false) {

 

$fakeInput.focus();

}

 

if (e.keyCode == Sys.UI.Key.tab && e.shiftKey == true) {

 

 

var $checkbox = $(".ruCheck", args.get_row());

 

 

if ($checkbox[0] != undefined) {

 

e.preventDefault();

$checkbox.focus();

}

 

else {

 

$fileInput.parent().focus();

}

}

});

}


I want that it should prevent enter key and upload doc on space bar . Above code works fine till upload of doc But after dialogue box opens and i uploaded doc now if  i press tab ideally it should go to next control in my case which is another next button but its not working like this it.after doc upload if i press tab it remains in upload control and if press tab twive it go to next button and then if i press enter key it dnt do postback but it clears uploaded file and remain focused in upload control.

I tried changing EnableFileInputSkinning property also it doesnt help.

one more thing if i use $selectButton.click() in place of $fileInput.click(); it works fine in IE9 but in IE8 and IE7 dialogue box doesnt open.


Thanks in advance

 

mahima jain
Top achievements
Rank 1
 asked on 13 Dec 2013
4 answers
208 views
Hello,

For my webapplication I use an AJAX Radgrid with something like 15 columns and 30 000 rows.
Filtering, sorting are ok and pretty fast, but when I try to group results it become really slow, and actually with my 30 000 rows it doesn't work. The ajax call returns a 500 error.

I saw a thread on this forum explaining that Radgrid is fast enough for 300 000 rows, so I don't understand what I'm doing wrong...

I use an AJAX Radgrid with a HeaderContextMenu, linked to an EntityDataSource (but I tried with a LinqDataSource too).
On the code below I removed most of the columns for readability, it's just several common GridBoundColumn.

The Telerik.Web.UI.dll version is 2010.2.929.35, Framework .NET 3.5


<telerik:RadGrid EnableViewState="false" OnPreRender="RadGrid1_PreRender" ExportSettings-ExportOnlyData="true" ExportSettings-IgnorePaging="true" ExportSettings-Csv-ColumnDelimiter="Semicolon" DataSourceID="EntityDataSourcePesee" AutoGenerateColumns="false" ID="RadGrid1"
                Width="1604px" AllowFilteringByColumn="True" AllowSorting="True"
                ShowFooter="True" AllowPaging="true" PageSize="5" runat="server" GridLines="None" EnableLinqExpressions="false" OnItemCommand="RadGrid1_ItemCommand" OnItemCreated="RadGrid1_ItemCreated"
                Culture="fr-FR"
                EnableHeaderContextMenu="true"
                EnableHeaderContextFilterMenu="true">
                <PagerStyle Mode="NextPrevAndNumeric" NextPageToolTip="Page suivante" PrevPageToolTip="Page précédente" FirstPageToolTip="Première page" LastPageToolTip="Dernière page" PageSizeLabelText="Nombre de pesées par page :" PagerTextFormat="{4} Pesées {2} à {3} sur {5} au total" />
                <GroupingSettings CaseSensitive="false" />
 
                <MasterTableView AutoGenerateColumns="false" IsFilterItemExpanded="false" PageSize="10"
                AllowFilteringByColumn="True" ShowFooter="True" TableLayout="Auto" CommandItemDisplay="Bottom">
                    <CommandItemSettings ExportToCsvText="Exporter la sélection" ShowAddNewRecordButton="false" ShowRefreshButton="false" ShowExportToCsvButton="true" />
                    <SortExpressions>
                       <telerik:GridSortExpression FieldName="PES_DATE" SortOrder="Descending" />
                    </SortExpressions>
                    <Columns>
                        <telerik:GridBoundColumn HeaderTooltip="Trier la colonne" FilterControlWidth="50px" DataField="SITE.SIT_LIBELLE" HeaderText="Site de pesage" FilterImageToolTip="Filtrer"
                            SortExpression="it.SITE.SIT_LIBELLE" UniqueName="SIT_LIBELLE">
                        </telerik:GridBoundColumn>
                        <telerik:GridBoundColumn HeaderTooltip="Trier la colonne" FilterControlWidth="50px" DataField="PES_DATE_ENTREE" HeaderText="Date d'entrée de la pesée" FilterImageToolTip="Filtrer"
                            SortExpression="PES_DATE_ENTREE" UniqueName="PES_DATE_ENTREE">
                             
                            <HeaderStyle Width="160px" />
                        </telerik:GridBoundColumn>
                        <telerik:GridBoundColumn HeaderTooltip="Trier la colonne" FilterControlWidth="50px" DataField="PES_DATE" HeaderText="Date de sortie de la pesée" FilterImageToolTip="Filtrer"
                            SortExpression="PES_DATE" UniqueName="PES_DATE"
                            >
                            <HeaderStyle Width="160px" />
                        </telerik:GridBoundColumn>
                        <telerik:GridTemplateColumn UniqueName="PES_TEMPS_PRESENCE" SortExpression="PES_TEMPS_PRESENCE" FilterImageToolTip="Filtrer"
                            InitializeTemplatesFirst="false" FilterControlToolTip="hh:mm:ss" DataType="System.String" DataField="PES_TEMPS_PRESENCE">
                            <HeaderTemplate>
                                <asp:LinkButton ToolTip="Trier la colonne" CssClass="Button" ID="btnSortTempsPresence" Text="Temps de présence (hh:mm:ss)" CommandName='Sort' CommandArgument='PES_TEMPS_PRESENCE' runat="server" />
                            </HeaderTemplate>
                            <ItemTemplate>
                                <%# formatTempsPresence((int?)Eval("PES_TEMPS_PRESENCE")) %>
                            </ItemTemplate>
                        </telerik:GridTemplateColumn>
                        <telerik:GridBoundColumn HeaderTooltip="Trier la colonne" FilterControlWidth="30px" DataField="PES_NUM_BON" HeaderText="N° Bon de pesée" FilterImageToolTip="Filtrer"
                            SortExpression="PES_NUM_BON" UniqueName="PES_NUM_BON">
                        </telerik:GridBoundColumn>
 
....
 
                    </Columns>
                </MasterTableView>
                <ClientSettings>
                    <Scrolling AllowScroll="false" />
                    <ClientEvents OnFilterMenuShowing="FilterMenuShowing" />
                </ClientSettings>
            </telerik:RadGrid>
         
           <asp:EntityDataSource ID="EntityDataSourcePesee" runat="server" ConnectionString="name=PeseesEntities"
              DefaultContainerName="PeseesEntities" EntitySetName="PESEE" Include="SITE"
              EnableUpdate="false" EnableDelete="false" EnableInsert="false">     
            </asp:EntityDataSource>
Radoslav
Telerik team
 answered on 13 Dec 2013
1 answer
239 views

Hello,

I have a problem with the custom sort in Oracle data base with a empty string and your RadGrid. When I use a custom sort in your RadGrid, the object result list it’s ok, but in the grid, the result isn’t the same. But, if I use buttons to sort the grid with the same query, the result it’s correct in my grid. I think the grid sort again my objects list in the SortCommand.

In Sql server, I have no problem with the same query. In Oracle, the empty value isn’t sort of the same order as  Sql Server. But why the grid sorts again my list of objects ?

Exemple code for custom sort :

Private Sub grdDetailTelerik_SortCommand(sender As Object, e As Telerik.Web.UI.GridSortCommandEventArgs) Handles grdDetailTelerik.SortCommand
    Dim sortingField As String = e.SortExpression
    Dim sortingOrder As String = e.NewSortOrder
    ActualResultPage = 0
    SetLastViewPage(0)
    SortColumn = sortingField
    SortDirection = sortingOrder
    grdDetailTelerik.DataSource = GetData(True) 'Get all of objet with my query
    grdDetailTelerik.Rebind()
End Sub


Custom sort :

SortColumn = Code

SortDirection = Ascending


Result list of Objet(Oracle) :         

Code = 001.0.0

Code = 001.0.0

Code = 001.0.0

Code = 001.0.0

Code = 001.0.0

Code = 001.0.0

Code = 001.0.0

Code = 099.9.0

Code = 099.9.0

Code = String.empty

Code = String.empty


Result list of Objet (Sql Server) :

Code = String.empty

Code = String.empty

Code = 001.0.0

Code = 001.0.0

Code = 001.0.0

Code = 001.0.0

Code = 001.0.0

Code = 001.0.0

Code = 001.0.0

Code = 099.9.0

Code = 099.9.0

Result in grid(Oracle), the order of sort isn’t ok in this example, my empty string is in top, but  :
Page 1 :
oracle_page1.png

Page 2 :
oracle_page2.png


Result in grid (Sql server) is ok:

Page 1 : sql_page1.png

Page 2 :
sql_page2.png


Sorry but I can not give you the entire code, I only submiting the list of objects and the result in the grid.


If you need another example, I will provide you, if it's possible

Thank's in advance !!

Pavlina
Telerik team
 answered on 13 Dec 2013
9 answers
351 views
I have a radcombobox with checkboxes. Everything works fine. But I need to achieve following. The first value is None and when it is selected all other values must be disabled. So that None and another value are not inserted together.

I will appreciate if someone can help me with this.
Thanks.
Gauri 
Gauri
Top achievements
Rank 1
 answered on 13 Dec 2013
2 answers
138 views
I have the following code in my Appointment Template.
<AppointmentTemplate>
<div><h1><%# Eval("Subject") %></h1><br /></div>
<hr />
<div><h2><%# Eval("Attributes['Rooms']") %></h2></div>
<div><h3><%# Eval("Attributes['StaffNames']") %></h3></div>
<div><h4><%# Eval("Start","{0:t}") %> - <%# Eval("End","{0:t}") %></h4></div>
</AppointmentTemplate>

This then creates the appointment like the image below.

What I need is for the hr line to move up a bit.

I have tried in the css stylesheet using margins and padding and nothing works
.hr
{
margin: 5px 0 !important;
border-width: 1px 0 0 0;
height: 1px;
}

When i remove the <br /> it pushes the line up but it still does not work with margins or padding.

Any suggestions.

Cheers

John M









Sean
Top achievements
Rank 2
 answered on 12 Dec 2013
3 answers
167 views
When i do a postback with RadButtons toggletype radio and have specific groupnames, it looses the groupname on postback and ajax panel wrapper. however i put asp:RadioButtons with their own specific groupnames and it doesnt have a problem, they still recognize each other.

  <telerik:RadAjaxManager runat="server" ID="RadAjaxManager1" DefaultLoadingPanelID="RadAjaxLoadingPanel1">
    <AjaxSettings>           
          <telerik:AjaxSetting AjaxControlID="RadButtonSetupSave">               
            <UpdatedControls>                   
                <telerik:AjaxUpdatedControl ControlID="RadAjaxPanelMain" LoadingPanelID="RadAjaxLoadingPanel1" />                   
            </UpdatedControls>
        </telerik:AjaxSetting>     
    </AjaxSettings>
    <ClientEvents OnResponseEnd="OnResponseEnd" OnRequestStart="OnRequestStart"/>
</telerik:RadAjaxManager>
 
<telerik:RadAjaxLoadingPanel runat="server" ID="RadAjaxLoadingPanel1" ToolTip="Please wait..."
    Height="50px" Width="50px" />   
<telerik:RadWindowManager ID="RadWindowManager1" runat="server" />
 
<telerik:RadAjaxPanel runat="server" ID="RadAjaxPanelMain" Width="1000px" Height="1000px">
 
    <div style="margin: 5px;">
 
        <telerik:RadButton runat="server" ID="RadButtonSetupSave" Text="Save"
            AutoPostBack="true" />
 
        <div style="float: left; width: 100%; margin: 15px;">
            <div style="float: left; width: 100%; margin: 5px;">
                <telerik:RadButton runat="server" ID="RadButton1" ButtonType="ToggleButton" Text="RadButton1"
                    ToggleType="Radio" AutoPostBack="false" GroupName="GroupNameRadButton" />
            </div>
 
            <div style="float: left; width: 100%; margin: 5px;">
                <telerik:RadButton runat="server" ID="RadButton2" ButtonType="ToggleButton" Text="RadButton2"
                    ToggleType="Radio" AutoPostBack="false" GroupName="GroupNameRadButton" />
            </div>
        </div>
 
        <div style="float: left; width: 100%; margin: 15px;">
            <div style="float: left; width: 100%; margin: 5px;">
                <asp:RadioButton runat="server" ID="RadioButton1" Text="RadioButton1"
                    AutoPostBack="false" GroupName="GroupNameRadioButton" />
            </div>
 
            <div style="float: left; width: 100%; margin: 5px;">
                <asp:RadioButton runat="server" ID="RadioButton2" Text="RadioButton2"
                    AutoPostBack="false" GroupName="GroupNameRadioButton" />
            </div>
        </div>
 
    </div>
</telerik:RadAjaxPanel>

So first time in the form, all the buttons behave accordingly, respecting the groupnames. After the save button is hit and a post back occurs the telerik buttons lose radio groupname functionally, but the standard asp buttons do not. Is there a workaround?

Thanks!


Danail Vasilev
Telerik team
 answered on 12 Dec 2013
7 answers
240 views
Hi Telerik team,
I am using Telerik version 2013.1.220.40.
I am unable to view the Collapse image of the RadPanelbar.
I am trying to dynamically add a RadGrid in a RadPanelbar(created at runtime as well).
Please see the below code for more clarification:

Dim radPanelBarForGrids As New RadPanelBar()
Dim panelItem As RadPanelItem = New RadPanelItem()
panelItem.Text = drv("trcNum")
panelItem.Expanded = True
Dim panelForItems As New Panel() 'Created a new panel
panelForItems.Controls.Add(escrowGrid) 'Added the grid in the panel
panelItem.Controls.Add(panelForItems) 'Added the panel in RadPanelItem
radPanelBarForGrids.ExpandMode = PanelBarExpandMode.FullExpandedItem
radPanelBarForGrids.Width = Unit.Percentage(100)
radPanelBarForGrids.Items.Add(panelItem) 'Added the RadPanelItem in RadPanelBar
phMultiGrids.Controls.Add(radPanelBarForGrids) ' Added the RadPanelBar in a PlaceHolder

Please see the attached image where I am unable to view the Collapse icon in my webapp.
I need to implement this fucntionality at the earliest.
So hoping for a quick response from you folks.

Thanks in Advance.

Shouvik


Kate
Telerik team
 answered on 12 Dec 2013
Narrow your results
Selected tags
Tags
+? more
Top users last month
Chester
Top achievements
Rank 1
Iron
Simon
Top achievements
Rank 1
Iron
Douglas
Top achievements
Rank 2
Iron
Iron
SUNIL
Top achievements
Rank 3
Iron
Iron
Iron
Marco
Top achievements
Rank 3
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Chester
Top achievements
Rank 1
Iron
Simon
Top achievements
Rank 1
Iron
Douglas
Top achievements
Rank 2
Iron
Iron
SUNIL
Top achievements
Rank 3
Iron
Iron
Iron
Marco
Top achievements
Rank 3
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?