I have RadSpreadsheet with 5 rows. If I copy 10 rows from Excel into RadSpreadsheet, it will show error message "Cannot paste, because area not the same size".
Is it possible to get RadSpreadsheet to automatically add rows when we paste data? (similar to the Kendo Spreadsheet Widget)
Please can you implement cell-based drag-and-drop in the radSpreadsheet control. The control looks amazing. This feature would enable me to completely rewrite and simplify a number of my applications and give them a much more professional look-and-feel. Regards, Paul.
The SpreadProcessing library gets into account the current server culture and the SpreadsheetDocumentProvider uses different decimal and list separators based on the culture while the RadSpreadsheet control supports only comma as a list separator and dot as a decimal separator. The JavaScript error that is thrown when using the "sv-SE" culture is caused by the fact that this culture uses the comma as a decimal separator and semicolon as a list separator. One possible workaround is to change the current thread's culture before creating the Spreadsheet's provider and then restore the culture.
Currently, a script solution is required to pre-select a sheet different from the first one.
function pageLoadHandler() {
var spreadsheet = $find("<%= RadSpreadsheet1.ClientID %>").get_kendoWidget();
var sheet = spreadsheet.sheetByName("Sheet1");
spreadsheet.activeSheet(sheet);
// Sys.Application.remove_load(pageLoadHandler);
}
Sys.Application.add_load(pageLoadHandler);
This script could be entirely loaded from the server-side following this article on how to properly register a script from the code-behind:
In support ticket #1058916 I was told I need to use an overriding pageLoad function to focus on the top of my page if I have a Spreadsheet control at the bottom of my page to prevent it from scrolling down to the spreadsheet when somebody navigates to the page. Was the Spreadsheet control designed to be the only element on the page? By forcing focus to be in cell A1 on pageLoad, it scrolls to the spreadsheet immediately and bypasses anything I might have above it. I would rather see a property on the spreadsheet control to focus on A1 on pageLoad that is defaulted to False rather than having to add a script. When I first navigate to any page without anchor tags in the URL, I expect to see the top of the page, not something that scrolls down to the spreadsheet and ignores anything above it!
I think it might be very useful to add to cell comments a html code and be able to do it programmatically.
Thank you
Hello,
The problem is as follows:
Link is not clickable when situated in a disabled cell.
Steps to reproduce.
1. Place a link in a cell or a range of cells
2. Disable the cell (range)
3. Click the link
Currently, the RadSpreadsheet supports only Dollar as currency. As a temporary workaround, the Kendo UI Spreadsheet (https://demos.telerik.com/kendo-ui/spreadsheet/index) can be used as demonstrated in this Dojo example: https://dojo.telerik.com/imAWasuJ - Select a cell with number as value - Open the formats dropdown - Choose the "More Formats..." option - Select "Currency" tab - Choose a currency from the dropdown - Choose the desired format.
The RadSpreadsheet server-side object does not support Named Ranges.
Workaround:
Nevertheless, you can load them client-side with the code below, by saving a JSON in a hidden field and loading it via the API:
protected void Page_Init(object sender, EventArgs e)
{
var path = Server.MapPath("~/App_Data/spreadsheet.xlsx");
var workbook = Workbook.Load(path);
HiddenField1.Value = workbook.ToJson();
}
<script>
function pageLoadHandler() {
var spreadsheet = $find("<%= RadSpreadsheet1.ClientID %>");
var hiddenfield = $get("<%= HiddenField1.ClientID %>");
if (hiddenfield.value) {
spreadsheet.get_kendoWidget().fromJSON(JSON.parse(hiddenfield.value))
hiddenfield.value = '';
}
// Sys.Application.remove_load(pageLoadHandler);
}
Sys.Application.add_load(pageLoadHandler);
</script>
<telerik:RadSpreadsheet runat="server" ID="RadSpreadsheet1"></telerik:RadSpreadsheet>
<asp:HiddenField runat="server" ID="HiddenField1" />
It would be very handy if we could set the active sheet of the spreadsheet programmatically, either from the client-side or server-side. We'd like to be able to load a spreadsheet and select a certain tab as the initial active sheet without the user having to click on it or having to have that tab be the first in the list. Thank you!
Currently the formatting feature (Bold, Italic and Underline) applies to entire cell content. It will be nice to have a partial cell content formatting feature (including subscript and superscript), means only few characters within the cell can be formatted instead of entire cell content (same as in Excel). Thanks
When I load the radspreadsheet from an excel file, the foreground color is not loaded. A workaround is to use the Kendo Spreadsheet widget directly which imports fore color: https://demos.telerik.com/kendo-ui/spreadsheet/server-side-import-export Repro steps go to https://demos.telerik.com/aspnet-ajax/spreadsheet/examples/import-export/defaultcs.aspx add some text with specific fore color save the excel file import the excel file Expected: there is no change Actual: the fore color is not imported. Also, font size changes, but see the related item for that
The default font size on the client is not saved explicitly on the Excel file, so the Excel defaults take over (11px Calibri), so upon subsequent import all cells will have that font.
Steps to repro:
go to https://demos.telerik.com/aspnet-ajax/spreadsheet/examples/import-export/defaultcs.aspx
export the file
import the file
Expected: nothing changes
Actual: all cells are 11px Calibri
Workaround: Set a default font when the cell font is null
public override void SaveWorkbook(Workbook workbook)
{
string path = "C:\\path-to-output.xlsx";
for (int i = 0; i < workbook.Sheets.Count; i++)
{
for (int j = 0; j < workbook.Sheets[i].Rows.Count; j++)
{
for (int l = 0; l < workbook.Sheets[i].Rows[i].Cells.Count; l++)
{
string fontFamily = workbook.Sheets[i].Rows[i].Cells[l].FontFamily;
workbook.Sheets[i].Rows[i].Cells[l].FontFamily = !string.IsNullOrEmpty(fontFamily) ? fontFamily : "Courier New";
double? fontSize = workbook.Sheets[i].Rows[i].Cells[l].FontSize;
workbook.Sheets[i].Rows[i].Cells[l].FontSize = fontSize.HasValue ? fontSize : 12;
}
}
}
workbook.Save(path);
}
A workaround is using directly the Kendo Spreadsheet widget as this will allow you to use its latest version that does not manifest this issue: https://demos.telerik.com/kendo-ui/spreadsheet/server-side-import-export Repro steps Go to https://demos.telerik.com/aspnet-ajax/spreadsheet/examples/import-export/defaultcs.aspx Go to an empty cell type some text change its font size (e.g., to 18) save the file import the file you just saved Expected: nothing changes Actual: (some) cells change their height and font size, not just the cell that was edited above
If you type 15 into the font size combo box and click away, a Javascript error is thrown and the font size of the selected cell does not change. If instead you type 16 and click away, the cell changes correctly. 16 is an option in the drop-down but 15 is not. Error message: RadSpreadsheetScripts.js:196 Uncaught TypeError: Cannot read property 'get_text' of null The font size combo box works correctly in the Kendo spreadsheet demo (both with the current and the 2017.1.124 Kendo version ). You can also press enter to commit your typed font size in the Kendo widget, but not in RadSpreadsheet. Steps to reproduce: 1. Open https://demos.telerik.com/aspnet-ajax/spreadsheet/examples/overview/defaultcs.aspx 2. Click inside the font -size dropdown 3. Type 15 and click outside the SpreadSheet Result: A JavaScript error is thrown.
related to https://github.com/telerik/kendo-ui-core/issues/3519 workaround for rounding function is using Custom Functions http://docs.telerik.com/kendo-ui/controls/data-management/spreadsheet/custom-functions kendo.spreadsheet.defineFunction("ROUND", function (x) { return Math.round(x); }).args([ ["x", "number"] ]); Cell cell = new Cell() { Index = 0, Formula = "=ROUND(1.2)", Bold = true, Background = "#fef0cd", Format = "$0" };
http://screencast.com/t/FJjlN3yw The error message reads 'ContextMenus' could not be initialized. Details: Object reference on set to an instance of an object.