Telerik Forums
UI for ASP.NET AJAX Forum
8 answers
149 views
Hi,

I am working on customizing the Telerik styles by registering a new skin completely as per the steps given in the Telerik skin registration tutorial. I have updated the style sheets and copied the Telerik folder from the Skin folder to my projects folder and updated the web config files app settings section to make my custom style work.

The issue is : When I updated the CSS of Telerik.Web.UI version 2011_1_519 the controls are not showing up properly, where as if I use the CSS of Telerik.Web.UI of some older version then the styles are appearing correctly.

Please help me with this issue, any help is greatly appreciated.

Thanks,
Mohammed Asif
Bozhidar
Telerik team
 answered on 25 Jun 2012
1 answer
298 views
Hi,

what's the deal about the new Telerik.ScriptManager.EnableEmbeddedjQuery feature? I look at the js produced and I can only see one difference:

/* START Telerik.Web.UI.Common.jQueryExternal.js */
if(typeof $telerik.$==="undefined"){$telerik.$=window.jQuery;
}
/* END Telerik.Web.UI.Common.jQueryExternal.js */
/* START Telerik.Web.UI.Calendar.RadDatePicker.js */

The jQueryExternal.js is embedded in front of the RadDatePicker.js.. it actually solved a $telerik.$ not defined problem I had with the RadDatePicker on some pages. And on some pages the above code wasn't injected in the js.

What's the correct way to use this new feature? Is the above the only difference this feature is gonna make and is it only for RadDatePicker?

By the way, I am adding my own "Telerik.Web.UI.Common.jQuery.js" and "Telerik.Web.UI.Common.jQueryInclude.js" in the code through RadScriptManager.
Dimitar Terziev
Telerik team
 answered on 25 Jun 2012
1 answer
203 views
Hello,

I have added Async file upload control in page and set display as none. like
<telerik:RadAsyncUpload ID="fuImport" runat="server" HttpHandlerUrl="~/CustomHandler.ashx"
         OnClientFileUploaded="onClientFileUploaded"  PersistConfiguration="true"
         MaxFileInputsCount="1"
         MultipleFileSelection="Disabled" OnClientFileSelected="CheckExtension"
         CssClass="jImport" OnClientAdded="onClientAdded" Style="display: none">
</telerik:RadAsyncUpload>
I have disabled embeded scripts in web.config
<add key="Telerik.EnableEmbeddedScripts" value="false"/>
for this I Have used custom handler HttpHandlerUrl="~/CustomHandler.ashx".

Now I have opened file dialog from menu client click(ImportData()  function ) instead of clicking on select button of file upload. Script are as below.
var $fileInput;
function onClientAdded(sender, args) {               
    if (sender.get_id() != undefined && sender.get_id() == 'fuImport') {                   
        //get file control instance from telerik upload control.
        $fileInput = $(".jImport").find(".ruFileInput");                   
 
    }
}
 
//check selected file is valid or not.
function CheckExtension(radUpload, eventArgs) {
    var input = eventArgs.get_fileInputField();               
    var fileExtension = input.value.substr(input.value.length - 3, 3);
    if (fileExtension != "xml") {
        alert(input.value + " does not have a valid extension.");
        radUpload.deleteFileInputAt(0);           
    }               
}
 
function ImportData()
{
    if ($fileInput != null) {
        //open dialog box for file selection.
        $fileInput.click();
    }  
}
function onClientFileUploaded(sender, args) {
    //check file is uploaded properly then perform import process.
    if (sender.getUploadedFiles().length > 0) {
        $(".jImport").css('display', 'none');
        $('.jImportButton').click();
    }
}
Now when we call ImportData function then file dialog is opened to select the file, after selecting file, upload process is not processing file for upload in IE, when I see this in IE Developer tool Network tab it's below url is executed multiple time
http://localhost/enigma/Telerik.RadUploadProgressHandler.ashx?AsyncProgress=true&RadUrid=3177d972-edfc-4992-aeee-1a1bbc50cdc50&_=1340265308915
RadUrid
changed in every request.

If I test same in FF and Chrome then it's worked perfect. Also If I set Display : block to file upload control and then upload files clicking on select button of file upload in IE then it's worked perfect.

Note : My site is hosted in Shared hosting server so I am not able to add handler in web.config.

Kindly Help me to resolve this issue.

Thanks in Advance.
Mohmedsadiq Modan
Bozhidar
Telerik team
 answered on 25 Jun 2012
3 answers
184 views

Hi Telerik team, I have the following problem.

I'm using Drag and drop in my solution and works perfect, but I have the option to UPDATE the RadGrid (original) from a RadWindow.

I don't know where is the problem, because in other radgrid without drag and drop works perfect,here is my code:

This is the main page:

 

<

telerik:RadAjaxManager ID="RadAjaxManager1" runat="server" OnAjaxRequest="RadAjaxManager1_AjaxRequest">

 

 

 

 

 

 

<AjaxSettings>

 

 

 

 

 

 

<telerik:AjaxSetting AjaxControlID="RadAjaxManager1">

 

 

 

 

 

 

<UpdatedControls>

 

 

 

 

 

 

 

<telerik:AjaxUpdatedControl ControlID="Gridfungenericasoriginal" />

 

 

 

 

 

 

</UpdatedControls>

 

 

 

 

 

 

</telerik:AjaxSetting>

 

 

 

 

 

 

  

 

<telerik:AjaxSetting AjaxControlID="Gridfungenericasoriginal">

 

 

 

 

 

 

<UpdatedControls>

 

 

 

 

 

 

<telerik:AjaxUpdatedControl ControlID="Gridfungenericasoriginal" />

 

 

 

 

 

 

<telerik:AjaxUpdatedControl ControlID="Gridfungenericascopia" />

 

 

 

 

 

 

</UpdatedControls>

 

 

 

 

 

 

</telerik:AjaxSetting>

 

 

 

 

 

 

<telerik:AjaxSetting AjaxControlID="Gridfungenericascopia">

 

 

 

 

 

 

<UpdatedControls>

 

 

 

 

 

 

<telerik:AjaxUpdatedControl ControlID="Gridfungenericascopia" />

 

 

 

 

 

 

<telerik:AjaxUpdatedControl ControlID="msggenericas" />

 

 

 

 

 

 

</UpdatedControls>

 

 

 

 

 

 

</telerik:AjaxSetting>

 

 

 

 

 

 

</AjaxSettings>

 

 

 

 

 

 

</telerik:RadAjaxManager>

 

 

 

 

 

 

<div>

 

 

 

 

 

 

 

<telerik:RadCodeBlock ID="RadCodeBlock1" runat="server">

 

 

 

 

 

 

<script type="text/javascript">

 

 

 

 

 

function ShowCatalogoGenericas()

 

{

window.radopen(

 

"Default4.aspx", "UserListDialog");

 

 

 

return false;

 

}

 

 

function refreshGrid(arg)

 

{

 

 

if(!arg)

 

{

$find(

 

"<%= RadAjaxManager1.ClientID %>").ajaxRequest("Rebind");

 

}

 

 

else

 

 

 

 

{

$find(

 

"<%= RadAjaxManager1.ClientID %>").ajaxRequest("RebindAndNavigate");

 

}

}

 

 

</script>

 

 

 

 

 

 

</telerik:RadCodeBlock> &nbsp;

 

 

 

 

 

 

 

 

 

<telerik:RadWindowManager ID="RadWindowManager1" runat="server">

 

 

 

 

 

 

<Windows>

 

 

 

 

 

 

<telerik:RadWindow ID="UserListDialog" runat="server" Title="Editing record" Height="400px"

 

 

 

 

 

 

Width="300px" Left="150px" ReloadOnShow="true" ShowContentDuringLoad="false" Modal="true" />

 

 

 

 

 

 

</Windows>

 

 

 

 

 

 

</telerik:RadWindowManager>

 

 

 

 

 

<asp:Button ID="Button3" runat="server" Text="genericas" OnClientClick="return ShowCatalogoGenericas();" /><br />

 

 

 

 

 

 

 

<div>

 

 

 

 

 

 

<telerik:RadScriptBlock runat="server" ID="scriptBlockGenericas">

 

 

 

 

 

 

<script type="text/javascript">

 

 

 

 

<!--

 

 

function onRowDroppingGenericas(sender,args) {

 

 

 

if(sender.get_id()=="<%=Gridfungenericasoriginal.ClientID %>") {

 

 

 

var node=args.get_destinationHtmlElement();

 

 

 

if(!isChildOf('<%=Gridfungenericascopia.ClientID %>',node)&&!isChildOf('<%=Gridfungenericasoriginal.ClientID %>',node)) {

 

args.set_cancel(

 

true);

 

}

}

 

 

else {

 

 

 

var node=args.get_destinationHtmlElement();

 

 

 

if(!isChildOf('trashCanGenericas',node)) {

 

args.set_cancel(

 

true);

 

}

 

 

else {

 

 

 

if(confirm("¿Eliminar datos?"))

 

args.set_destinationHtmlElement($get(

 

'trashCanGenericas'));

 

 

 

else

 

 

 

 

args.set_cancel(

 

true);

 

}

}

}

 

 

function isChildOf(parentId,element) {

 

 

 

while(element) {

 

 

 

if(element.id&&element.id.indexOf(parentId)> -1) {

 

 

 

return true;

 

}

element=element.parentNode;

}

 

 

return false;

 

}

-->

 

 

</script>

 

 

 

 

 

 

</telerik:RadScriptBlock>

 

 

 

 

 

 

<div style="float:left; padding:0 6px 0 10px">

 

 

 

 

 

 

<telerik:RadGrid ID="Gridfungenericasoriginal" runat="server" AllowMultiRowSelection="True" AllowFilteringByColumn="True" Width="430px" Font-Bold="True" Font-Names="Tahoma" Font-Size="Small" OnNeedDataSource="Gridfungenericasoriginal_NeedDataSource" OnRowDrop="Gridfungenericasoriginal_RowDrop" OnColumnCreated="Gridfungenericasoriginal_ColumnCreated">

 

 

 

 

 

 

<MasterTableView DataKeyNames="clave_divis,clave_pues,clave_funcion_generica,grupo_orga" TableLayout="Fixed" NoMasterRecordsText="No hay datos para mostrar." Font-Bold="True" Font-Names="Tahoma" Font-Size="X-Small" CommandItemDisplay="Top">

 

 

 

 

 

 

<HeaderStyle Font-Bold="True" Font-Names="Tahoma" Font-Size="Small" />

 

 

 

 

 

 

<FooterStyle Font-Bold="True" Font-Names="Tahoma" Font-Size="Medium" />

 

 

 

 

 

 

<ItemStyle Font-Bold="True" Font-Names="Tahoma" Font-Size="X-Small" />

 

 

 

 

 

 

</MasterTableView>

 

 

 

 

 

 

<ClientSettings AllowRowsDragDrop="True">

 

 

 

 

 

 

<Selecting AllowRowSelect="True" EnableDragToSelectRows="False"/>

 

 

 

 

 

 

<ClientEvents OnRowDropping="onRowDroppingGenericas" />

 

 

 

 

 

 

<Scrolling AllowScroll="True" UseStaticHeaders="True"/>

 

 

 

 

 

 

<DataBinding FilterParameterType="String" SortParameterType="String">

 

 

 

 

 

 

</DataBinding>

 

 

 

 

 

 

</ClientSettings>

 

 

 

 

 

 

</telerik:RadGrid>

 

 

 

 

 

 

</div>

 

 

 

 

 

 

<br />

 

 

 

 

 

 

<div style="float:right; padding:0 10px 0 6px; font-weight: bolder; color: black;">

 

 

 

 

Para agregar funcion generica a este perfil arrastre elementos de la tabla izquierda.

 

<br />

 

 

 

 

 

 

<telerik:RadGrid ID="Gridfungenericascopia" runat="server" AllowMultiRowSelection="True" GridLines="None" Width="400px" OnNeedDataSource="Gridfungenericascopia_NeedDataSource" OnRowDrop="Gridfungenericascopia_RowDrop" OnColumnCreated="Gridfungenericascopia_ColumnCreated">

 

 

 

 

 

 

<MasterTableView DataKeyNames="clave_divis, clave_pues,clave_funcion_generica, grupo_orga" HeaderStyle-Font-Bold="true" HeaderStyle-Font-Names="Tahoma" HeaderStyle-Font-Size="Small" ItemStyle-Font-Bold="true" ItemStyle-Font-Names="Tahoma" ItemStyle-Font-Size="Small" Font-Bold="true" Font-Names="Tahoma" Font-Size="Small">

 

 

 

 

 

 

<NoRecordsTemplate>

 

 

 

 

 

 

<div style="height: 30px; cursor: pointer;">

 

 

 

 

No hay datos para mostrar

 

</div>

 

 

 

 

 

 

</NoRecordsTemplate>

 

 

 

 

 

 

<HeaderStyle Font-Bold="True" Font-Names="Tahoma" Font-Size="Small" />

 

 

 

 

 

 

</MasterTableView>

 

 

 

 

 

 

<ClientSettings AllowRowsDragDrop="True">

 

 

 

 

 

 

<Selecting AllowRowSelect="True" EnableDragToSelectRows="False" />

 

 

 

 

 

 

<ClientEvents OnRowDropping="onRowDroppingGenericas" />

 

 

 

 

 

 

<Scrolling AllowScroll="True" UseStaticHeaders="True" />

 

 

 

 

 

 

</ClientSettings>

 

 

 

 

 

 

</telerik:RadGrid>

 

 

 

 

 

 

</div>

 

 

 

 

 

 

<br />

 

 

 

 

 

 

<br />

 

 

 

 

 

 

<br />

 

 

 

 

 

 

 

<div style="clear: both;">

 

 

 

 

 

 

<!-- -->

 

 

 

 

 

 

</div>

 

 

 

 

 

 

<div class="exFooter">

 

 

 

 

 

 

<br />

 

 

 

 

 

 

<a id="trashCanGenericas" href="#" onclick="return false;">Papelera de reciclaje</a>

 

 

 

 

 

 

<div class="exMessage" runat="server" id="msggenericas" visible="false" enableviewstate="false">

 

 

 

 

Dato(s) eliminados con exito

 

 

</div>

 

 

 

 

 

 

</div>

 

 

 

 

 

 

</div>

 

 

 

 

 

 

</div>

 

 

 

 

protected

void RadAjaxManager1_AjaxRequest(object sender, AjaxRequestEventArgs e)

 

{

 

 

if (e.Argument == "Rebind")

 

{

Gridfungenericasoriginal.MasterTableView.SortExpressions.Clear();

Gridfungenericasoriginal.MasterTableView.GroupByExpressions.Clear();

Gridfungenericasoriginal.Rebind();

 

}

 

 

else if (e.Argument == "RebindAndNavigate")

 

{

Gridfungenericasoriginal.MasterTableView.SortExpressions.Clear();

Gridfungenericasoriginal.MasterTableView.GroupByExpressions.Clear();

Gridfungenericasoriginal.MasterTableView.CurrentPageIndex = Gridfungenericasoriginal.MasterTableView.PageCount - 1;

Gridfungenericasoriginal.Rebind();

 

}

}

 



And here is my RadWindow to edit Gridfungenericasoriginal (drag and drop)

 

<

 

script type="text/javascript">

 

 

 

 

 

 

function CloseAndRebind(args)

 

{

GetRadWindow().Close();

GetRadWindow().BrowserWindow.refreshGrid(args);

}

 

 

 

function GetRadWindow()

 

{

 

 

var oWindow = null;

 

 

 

if (window.radWindow) oWindow = window.radWindow;

 

 

 

 

 

 

else if (window.frameElement.radWindow) oWindow = window.frameElement.radWindow;

 

 

 

 

 

 

 

return oWindow;

 

}

 

 

function CancelEdit()

 

{

GetRadWindow().Close();

}

 

 

</script>

 

 

 

 

 

 

 

<br />

 

 

 

 

 

 

<br />

 

 

 

 

 

 

<telerik:RadGrid ID="RadGrid1" runat="server" AllowAutomaticUpdates="True" AllowPaging="True"

 

 

 

 

 

 

AutoGenerateEditColumn="True" DataSourceID="SqlDataSource1" GridLines="None" OnItemUpdated="RadGrid1_ItemUpdated">

 

 

 

 

 

 

<MasterTableView AutoGenerateColumns="False" DataKeyNames="clave_divis,grupo_orga,clave_pues,clave_funcion_generica"

 

 

 

 

 

 

DataSourceID="SqlDataSource1">

 

 

 

 

 

 

<RowIndicatorColumn>

 

 

 

 

 

 

<HeaderStyle Width="20px" />

 

 

 

 

 

 

</RowIndicatorColumn>

 

 

 

 

 

 

<ExpandCollapseColumn>

 

 

 

 

 

 

<HeaderStyle Width="20px" />

 

 

 

 

 

 

</ExpandCollapseColumn>

 

 

 

 

 

 

<Columns>

 

 

 

 

 

 

<telerik:GridBoundColumn DataField="clave_divis" HeaderText="clave_divis" ReadOnly="True"

 

 

 

 

 

 

SortExpression="clave_divis" UniqueName="clave_divis">

 

 

 

 

 

 

</telerik:GridBoundColumn>

 

 

 

 

 

 

<telerik:GridBoundColumn DataField="grupo_orga" DataType="System.Int32" HeaderText="grupo_orga"

 

 

 

 

 

 

ReadOnly="True" SortExpression="grupo_orga" UniqueName="grupo_orga">

 

 

 

 

 

 

</telerik:GridBoundColumn>

 

 

 

 

 

 

<telerik:GridBoundColumn DataField="clave_pues" HeaderText="clave_pues" ReadOnly="True"

 

 

 

 

 

 

SortExpression="clave_pues" UniqueName="clave_pues">

 

 

 

 

 

 

</telerik:GridBoundColumn>

 

 

 

 

 

 

<telerik:GridBoundColumn DataField="clave_funcion_generica" DataType="System.Int32"

 

 

 

 

 

 

HeaderText="clave_funcion_generica" ReadOnly="True" SortExpression="clave_funcion_generica"

 

 

 

 

 

 

UniqueName="clave_funcion_generica">

 

 

 

 

 

 

</telerik:GridBoundColumn>

 

 

 

 

 

 

<telerik:GridBoundColumn DataField="puesto" HeaderText="puesto" SortExpression="puesto"

 

 

 

 

 

 

UniqueName="puesto">

 

 

 

 

 

 

</telerik:GridBoundColumn>

 

 

 

 

 

 

<telerik:GridBoundColumn DataField="funcion_generica" HeaderText="funcion_generica"

 

 

 

 

 

 

SortExpression="funcion_generica" UniqueName="funcion_generica">

 

 

 

 

 

 

</telerik:GridBoundColumn>

 

 

 

 

 

 

</Columns>

 

 

 

 

 

 

</MasterTableView>

 

 

 

 

 

 

</telerik:RadGrid><asp:SqlDataSource ID="SqlDataSource1" runat="server" ConnectionString="<%$ ConnectionStrings:perfiles_dnConnectionString %>"

 

 

 

 

 

 

ProviderName="<%$ ConnectionStrings:perfiles_dnConnectionString.ProviderName %>"

 

 

 

 

 

 

SelectCommand="SELECT * FROM funciones_genericas" UpdateCommand="UPDATE funciones_genericas SET funcion_generica=@funcion_generica WHERE clave_divis=@clave_divis AND grupo_orga=@grupo_orga AND clave_pues=@clave_pues AND clave_funcion_generica=@clave_funcion_generica">

 

 

 

 

 

 

</asp:SqlDataSource>

 

 

 

 

protected

 

void RadGrid1_ItemUpdated(object source, Telerik.Web.UI.GridUpdatedEventArgs e)

 

{

ClientScript.RegisterStartupScript(Page.GetType(),

 

"mykey", "CloseAndRebind();", true);

 

}

 

 

please help me.

Thanks in advance.

 

Radoslav
Telerik team
 answered on 25 Jun 2012
3 answers
621 views
I have been trying to export my radgrid into CSV format, but somehow it'snot working even after following settings.
 <CommandItemSettings ShowExportToExcelButton="true" ShowExportToCsvButton="true"
            ShowAddNewRecordButton="false" ShowRefreshButton="false" />

It does not even hit  OnGridExporting="radInvoiceDetails_GridExporting" method.


Shinu
Top achievements
Rank 2
 answered on 25 Jun 2012
5 answers
185 views

I am using radtree view in my application.

I have a scenario in that on one tab selection the tree should show checkboxes & on other tab It shouldn’t display the check boxes.

Which I am handling through the tree.CheckBoxes Property making it true or false I am not even binding the tree again.

But at that time trees checkboxes is losing its state.(i.e. whatever nodes I have selected become unselected when I come to previous tab)

Is there any way to maintain the state of checkboxes of tree?

Thanks in advance

                               

Plamen
Telerik team
 answered on 25 Jun 2012
1 answer
146 views
My boss wanted me to find out what is possible with you SharePoint control set. We have a large project that requires edits and updates to excel spreadsheets. This requires the use of formulas and row inserts by the use of sharepoint web parts. The functionally would have to be more complex then that of a radgrid as spreadsheet rows would have to be inserted dynamically and formulas would be needed to update the data from the updated cells into the newly created inserted cells. Please send me documentation on if your controls could handle such a task so we can evaluate the purchase of your sharepoint control suite.

Thanks,


Steve Holdorf
Maria Ilieva
Telerik team
 answered on 25 Jun 2012
3 answers
255 views
Hello,

I have a RadImageEditor and Buttons in a User Control.I am loading the user control dynamically in a RadDock on a page.
I am facing a problem in firing the click event of the Buttons.The button click events are not getting fired.However if i remove the RadImageEditor everything works fine.

Please suggest.


Thanks
Gaurav Gupta


Rumen
Telerik team
 answered on 25 Jun 2012
1 answer
159 views

I have a notes columns and following is the declaration. I am note able to save and display the new line.
While i/p values I am able to go to new line, but while displaying 1st line and 2nd line are together in 1 line.

<telerik:GridTemplateColumn UniqueName="Notes"> 

<ItemTemplate>

 

<asp:Label ID="test" runat="server" Text='<%# Eval("NOTE_DESC") %>' />

 

</ItemTemplate>

 

<EditItemTemplate>

 

<telerik:RadTextBox ID="tnotes" runat="server" TextMode="MultiLine" Text='<%# Bind("NOTE_DESC") %>' Width="300px" Height="200px">

 

</telerik:RadTextBox> 

</EditItemTemplate>

 

</telerik:GridTemplateColumn>

Am I missing some settings here.

Thanks

Shinu
Top achievements
Rank 2
 answered on 25 Jun 2012
1 answer
77 views

Hi Team,

I need to get the GridBoundColumn values into the new record row when we click the Add Record button.

I am able to find the previous values of lables under GridTemplateColumn but above mention is not clear.

Please let me know how it could be handled.

Regards

SS Bhogal

Shinu
Top achievements
Rank 2
 answered on 25 Jun 2012
Narrow your results
Selected tags
Tags
+? more
Top users last month
Jake
Top achievements
Rank 1
RBarnes
Top achievements
Rank 1
Iron
Iron
Rami
Top achievements
Rank 1
Iron
Veteran
Nathan
Top achievements
Rank 1
Kumeri
Top achievements
Rank 1
Iron
Veteran
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Jake
Top achievements
Rank 1
RBarnes
Top achievements
Rank 1
Iron
Iron
Rami
Top achievements
Rank 1
Iron
Veteran
Nathan
Top achievements
Rank 1
Kumeri
Top achievements
Rank 1
Iron
Veteran
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?