Telerik Forums
UI for ASP.NET AJAX Forum
4 answers
485 views

I have several documents I am importing in order to merge them into one document.  This works find on all of them but one.  On the import statement I get a null reference exception.  I have verified that the stream is not empty.  Does anyone have any clues for a work-around or fix?

var docToBeMerged = new DocxFormatProvider().Import(fileStreamForMergeTarget);

 

Sack Trace:

NullReferenceException: Object reference not set to an instance of an object.

   at Telerik.Windows.Documents.Flow.FormatProviders.Docx.Model.Elements.Document.ParagraphContentElementBase.MoveInlinesToParagraph()
   at Telerik.Windows.Documents.Flow.FormatProviders.Docx.Model.Elements.Document.HyperlinkElement.OnAfterRead(IDocxImportContext context)
   at Telerik.Windows.Documents.FormatProviders.OpenXml.Model.Elements.OpenXmlElementBase`3.OnAfterRead(IOpenXmlImportContext context)
   at Telerik.Windows.Documents.FormatProviders.OpenXml.Model.Elements.OpenXmlElementBase.Read(IOpenXmlReader reader, IOpenXmlImportContext context)
   at Telerik.Windows.Documents.FormatProviders.OpenXml.Model.Elements.OpenXmlElementBase.ReadChildElements(IOpenXmlReader reader, IOpenXmlImportContext context)
   at Telerik.Windows.Documents.FormatProviders.OpenXml.Model.Elements.OpenXmlElementBase.Read(IOpenXmlReader reader, IOpenXmlImportContext context)
   at Telerik.Windows.Documents.FormatProviders.OpenXml.Model.Elements.OpenXmlElementBase.ReadChildElements(IOpenXmlReader reader, IOpenXmlImportContext context)
   at Telerik.Windows.Documents.FormatProviders.OpenXml.Model.Elements.OpenXmlElementBase.Read(IOpenXmlReader reader, IOpenXmlImportContext context)
   at Telerik.Windows.Documents.FormatProviders.OpenXml.Model.Elements.OpenXmlElementBase.ReadChildElements(IOpenXmlReader reader, IOpenXmlImportContext context)
   at Telerik.Windows.Documents.FormatProviders.OpenXml.Model.Elements.OpenXmlElementBase.Read(IOpenXmlReader reader, IOpenXmlImportContext context)
   at Telerik.Windows.Documents.FormatProviders.OpenXml.Model.Parts.OpenXmlPartBase.Import(IOpenXmlReader reader, IOpenXmlImportContext context)
   at Telerik.Windows.Documents.FormatProviders.OpenXml.OpenXmlImporter`1.ImportXlsxPartFromArchive(ZipArchiveEntry zipEntry, OpenXmlPartBase part, IOpenXmlImportContext context)
   at Telerik.Windows.Documents.FormatProviders.OpenXml.OpenXmlImporter`1.Import(Stream input, IOpenXmlImportContext context)
   at Telerik.Windows.Documents.Flow.FormatProviders.Docx.DocxFormatProvider.ImportOverride(Stream input)
   at Telerik.Windows.Documents.Common.FormatProviders.FormatProviderBase`1.Import(Stream input)
   at DocumentProcessor.DocumentProcessor.GetPdf(List`1 roles, List`1 restrictedRoles, List`1 files, Boolean includeToc, Boolean includeFooter) in C:\Projects\DocumentProcessor\DocumentProcessor\DocumentProcessor.cs:line 172
   at DocumentProcessor.Default.GetPdfDoc(String role) in C:\Projects\DocumentProcessor\DocumentProcessorHarness\Default.aspx.cs:line 47
   at DocumentProcessor.Default.Test1_OnClick(Object sender, EventArgs e) in C:\Projects\DocumentProcessor\DocumentProcessorHarness\Default.aspx.cs:line 35
   at Telerik.Web.UI.RadButton.OnClick(ButtonClickEventArgs e)
   at Telerik.Web.UI.RadButton.RaisePostBackEvent(String eventArgument)
   at Telerik.Web.UI.RadButton.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String eventArgument)
   at System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument)
   at System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData)
   at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
   
   
   

Tanya
Telerik team
 answered on 05 Oct 2018
2 answers
2.3K+ views
Hi, 
    I am using Telerik Rad Grid. I want my first column to be sorted by default in decending order and then by second column. Kindly help me to acomplish this.

Thanks in advance.
konnyaku
Top achievements
Rank 1
 answered on 05 Oct 2018
1 answer
297 views
Hi,
I integrated a Telerik – RadGrid control, that I bound to a large DataSource (server side), using an SQL request that join two tables having 2 000 000 rows.
I used RadAjaxPanel to avoid post back and reduce the response time.
The problem is that in every NeedDataSource event, I select all the 2 000 000 rows from the DataBase, which takes a long time.
To fix this problem I edited the SQL request using the arguments of the RadGrid (PageIndex and PageSize). But we have an application that includes a 200+ Grid, so we can’t do the same big modification to all the grids.
Is there a solution or a better way to implement pagination, sorting, grouping, … without having to select all the DataSource from DataBase? Or if there is a way autogenerate SQL Request in pagination, sorting, grouping, …
Marin Bratanov
Telerik team
 answered on 04 Oct 2018
2 answers
140 views

Hi,

I have a radgrid and I have set the width along with that I have given Header style width so that Horizontal Scroll bar appears. Everything works pretty fine locally but after deployment on development server I do not see Horizontal bat and Columns resixe automatically. Any help is appreciated.

Suryadevara
Top achievements
Rank 1
 answered on 04 Oct 2018
2 answers
349 views

Hi, I have a radgrid, which has some columns created dynamically from code-behind, and rest of the columns are auto generated coming from the DataSource. The dynamic columns are : 1) CheckBox Column created through GridClientSelectColumn from backend(VB) 2)the remaining are a DropDown an TextBox created inside a GridTemplateColumn from backend(VB). I have also created hidden input field, to hold the values  fromt he dropdown and the textbox respectively. 

I followed some of the solution provided in the forum, Unfortunately, no success. Can anybody please help me to export this data. As of now, if i try to export in excel or pdf, I am getting a blank column in place of the textbox and "select" in the column representing the DropdownList and "False" in the column representing the CheckBox Column. Please advice or point to me in the right direction

I tried iterating the entire grid, and copy the selected value from the dropdownlist, but it is throwing a NullException, the values from TextBox is Empty

Thanks, in advance

Elena
Telerik team
 answered on 04 Oct 2018
3 answers
127 views

I have an issue that when editor loads in first, it shows the default font-size = 3. That seems nice.
But when you start typing, it will will include in html the selected font size.

only if you select some text, change the font size from 3 to something else, and then change back to 3, it will include the contents in html

Is there anyway that it shows the default font size = 3, so it should auto append HTML for that font size=3 in the html?

 

thank you

 

Rumen
Telerik team
 answered on 04 Oct 2018
1 answer
201 views

Hi,
    I'm trying to set the toggle state of a button in a togglelist from client side code but nothing I try works. 

<telerik:RibbonBarGroup Text="Status Filter">
           <Items>
               <telerik:RibbonBarToggleList>
                   <ToggleButtons>
                       <telerik:RibbonBarToggleButton Value="StatusFilterAll" Size="Medium" Text="All" Toggled="true" />
                       <telerik:RibbonBarToggleButton Value="StatusFilterOpen" Size="Medium" Text="Open" />
                       <telerik:RibbonBarToggleButton Value="StatusFilterInProgress" Size="Medium" Text="In Progress" />
                       <telerik:RibbonBarToggleButton Value="StatusFilteronHold" Size="Medium" Text="On Hold" />
                       <telerik:RibbonBarToggleButton Value="StatusFilterClosed" Size="Medium" Text="Closed" />
                       <telerik:RibbonBarToggleButton Value="StatusFilterAllExClosed" Size="Medium" Text="All Except Closed" />
                   </ToggleButtons>
               </telerik:RibbonBarToggleList>
           </Items>
       </telerik:RibbonBarGroup>

 

I have tried 

ServiceDeskRibbonbar.findToggleButtonByValue("StatusFilterAll").get_toggleList().set_toggledButton(ServiceDeskRibbonbar.findToggleButtonByValue("StatusFilterAll" ))

 

This does not seem to do anything. I have also tried 

ServiceDeskRibbonbar.findToggleButtonByValue("StatusFilterAll" ).set_toggled(true)

 

This selects that item but the previous item still stays selected as well and the OnClientToggleListToggled is never fired.

So what is the correct way to achieve this?

Thanks

Marin Bratanov
Telerik team
 answered on 04 Oct 2018
1 answer
138 views

I  installed Telerik version "2010.3.1109.40" on  windows 10 machine and launched an asp.net web-site , i am getting an error "The page cannot be accessed because the related configuration data for the page is invalid and points to "Telerik_Web_UI_WebResource_axd" in web.config file. See attached file

Any ideas on how to trouble shoot.

Marin Bratanov
Telerik team
 answered on 04 Oct 2018
3 answers
376 views
Hello,

I am developing a web site to target mobile devices and So to save space i want to display error messages inside the Radtextbox if validation fails. Is this possible?

Thank you,
Saira
Marin Bratanov
Telerik team
 answered on 04 Oct 2018
1 answer
122 views

Since there doesn't appear to be a Telerik RequiredFieldValidator (or something similar) and we have to use the asp:RequiredFieldValidator ... how can we "Skin" the resulting Text output when validation is trigger?  Without being able to Skin validators thru the SkinManager it sorta makes the asp:RequiredFieldValidator useless.

Any suggestions?  Alternative approaches?

ON A SIDE NOTE: The sample code to display the validator error text inside the RadTextBox control doesn't appear to work: https://docs.telerik.com/devtools/aspnet-ajax/controls/textbox/features/validation

 

Cheers, Rob.

Marin Bratanov
Telerik team
 answered on 04 Oct 2018
Narrow your results
Selected tags
Tags
+? more
Top users last month
Rob
Top achievements
Rank 3
Bronze
Bronze
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
Bronze
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?