This is a migrated thread and some comments may be shown as answers.

LoadRTFContent exception

3 Answers 117 Views
Editor
This is a migrated thread and some comments may be shown as answers.
Matt Baker
Top achievements
Rank 1
Matt Baker asked on 28 Sep 2010, 02:29 AM
I'm getting the below exception when loading an RTF file from a stream.
All fonts used on the existing system (that works - not using telerik though) have been copied to the dev platform in the hope of eliminating some suspects.
If you wish I can post the RTF.
Any help appreciated.

{"Value cannot be null.\r\nParameter name: format"}
 at System.String.Format(IFormatProvider provider, String format, Object[] args)
   at Itenso.Sys.StringTool.FormatSafeInvariant(String format, Object[] args)
   at Itenso.Sys.StringsBase.Format(String format, Object[] args)
   at Telerik.Web.UI.Editor.Rtf.Strings.UndefinedFont(String fontId)
   at Telerik.Web.UI.Editor.Rtf.Interpreter.RtfInterpreter.Telerik.Web.UI.Editor.Rtf.IRtfElementVisitor.VisitTag(IRtfTag tag)
   at Telerik.Web.UI.Editor.Rtf.Model.RtfTag.DoVisit(IRtfElementVisitor visitor)
   at Telerik.Web.UI.Editor.Rtf.Model.RtfElement.Visit(IRtfElementVisitor visitor)
   at Telerik.Web.UI.Editor.Rtf.Interpreter.RtfInterpreter.VisitChildrenOf(IRtfGroup group)
   at Telerik.Web.UI.Editor.Rtf.Interpreter.RtfInterpreter.Telerik.Web.UI.Editor.Rtf.IRtfElementVisitor.VisitGroup(IRtfGroup group)
   at Telerik.Web.UI.Editor.Rtf.Model.RtfGroup.DoVisit(IRtfElementVisitor visitor)
   at Telerik.Web.UI.Editor.Rtf.Model.RtfElement.Visit(IRtfElementVisitor visitor)
   at Telerik.Web.UI.Editor.Rtf.Interpreter.RtfInterpreter.VisitChildrenOf(IRtfGroup group)
   at Telerik.Web.UI.Editor.Rtf.Interpreter.RtfInterpreter.Telerik.Web.UI.Editor.Rtf.IRtfElementVisitor.VisitGroup(IRtfGroup group)
   at Telerik.Web.UI.Editor.Rtf.Model.RtfGroup.DoVisit(IRtfElementVisitor visitor)
   at Telerik.Web.UI.Editor.Rtf.Model.RtfElement.Visit(IRtfElementVisitor visitor)
   at Telerik.Web.UI.Editor.Rtf.Interpreter.RtfInterpreter.VisitChildrenOf(IRtfGroup group)
   at Telerik.Web.UI.Editor.Rtf.Interpreter.RtfInterpreter.Telerik.Web.UI.Editor.Rtf.IRtfElementVisitor.VisitGroup(IRtfGroup group)
   at Telerik.Web.UI.Editor.Rtf.Model.RtfGroup.DoVisit(IRtfElementVisitor visitor)
   at Telerik.Web.UI.Editor.Rtf.Model.RtfElement.Visit(IRtfElementVisitor visitor)
   at Telerik.Web.UI.Editor.Rtf.Interpreter.RtfInterpreter.VisitChildrenOf(IRtfGroup group)
   at Telerik.Web.UI.Editor.Rtf.Interpreter.RtfInterpreter.Telerik.Web.UI.Editor.Rtf.IRtfElementVisitor.VisitGroup(IRtfGroup group)
   at Telerik.Web.UI.Editor.Rtf.Model.RtfGroup.DoVisit(IRtfElementVisitor visitor)
   at Telerik.Web.UI.Editor.Rtf.Model.RtfElement.Visit(IRtfElementVisitor visitor)
   at Telerik.Web.UI.Editor.Rtf.Interpreter.RtfInterpreter.VisitChildrenOf(IRtfGroup group)
   at Telerik.Web.UI.Editor.Rtf.Interpreter.RtfInterpreter.InterpretContents(IRtfGroup rtfDocument)
   at Telerik.Web.UI.Editor.Rtf.Interpreter.RtfInterpreter.DoInterpret(IRtfGroup rtfDocument)
   at Telerik.Web.UI.Editor.Rtf.Interpreter.RtfInterpreterBase.Interpret(IRtfGroup rtfDocument)
   at Telerik.Web.UI.Editor.Rtf.Support.RtfInterpreterTool.Interpret(IRtfGroup rtfDocument, IRtfInterpreterListener[] listeners)
   at Telerik.Web.UI.Editor.Rtf.Support.RtfInterpreterTool.BuildDoc(IRtfGroup rtfDocument, IRtfInterpreterListener[] listeners)
   at Telerik.Web.UI.Editor.Rtf.Support.RtfInterpreterTool.BuildDoc(Stream rtfTextSource, IRtfInterpreterListener[] listeners)
   at Telerik.Web.UI.Editor.Rtf.Rtf2Html.StreamToHtml(Stream stream)
   at Telerik.Web.UI.RadEditor.LoadRtfContent(Stream rtfStream)
   at <namechangedtoprotecttheinnocent>_Click(Object sender, EventArgs e) in C:\Projects\project\project2\pagename.aspx.cs:line 700

3 Answers, 1 is accepted

Sort by
0
Dobromir
Telerik team
answered on 29 Sep 2010, 02:34 PM
Hi Matt,

We are not aware of this problem and you are first one to report it. However, I was unable to reproduce the problem on our side. Could you please provide more detailed information on the subject?
  • Which version of RadControls for ASP.NET AJAX and .NET Framework are used in the application?
  • Could you please open a support ticket and provide sample runnable project reproducing the problem containing the problematic RFT document so we can investigate it further?

Looking forward to hearing from you,
Dobromir
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
0
sawyer
Top achievements
Rank 1
answered on 03 Nov 2010, 01:40 PM
I have the same problem.

Dim pdfBytes As Byte() = My value in byte
Dim StreamObject As Stream = New MemoryStream(pdfBytes)
RadEditor1.LoadRtfContent(StreamObject)

My streamObject length is 14, but I have error on RadEditor1.LoadRtfContent {"Value cannot be null.\r\nParameter name: format"}.

Thank's
0
Dobromir
Telerik team
answered on 08 Nov 2010, 08:21 AM
Hi Tom,

Could you please open a support ticket and provide a the problematic content that you are trying to export so we can investigate the issue further?

Sincerely yours,
Dobromir
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
Tags
Editor
Asked by
Matt Baker
Top achievements
Rank 1
Answers by
Dobromir
Telerik team
sawyer
Top achievements
Rank 1
Share this question
or