We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

Aspose.Words.ReportingServices - Object reference not set to an instance of an object

While trying to evaluate Aspose.Words.ReportingServices in one of my projects using a temperoary license. I am getting the below error.
Please kindly suggest.

Microsoft.Reporting.WinForms.LocalProcessingException
  HResult=0x80131500
  Message=An error occurred during local report processing.
  Source=Aspose.Words.ReportingServices
  StackTrace:
   at ‪‫‭‎‌‮‭‌‎‌‌‏​‬‌‮‌‭‏‮‬‏‏‫‮.‮‪‫‫‬‪‭‫‏‮‭‏‬‍‍‍‍‫‮(String , Boolean , String , CreateAndRegisterStream )
   at ‪‫‭‎‌‮‭‌‎‌‌‏​‬‌‮‌‭‏‮‬‏‏‫‮.‎‫‪‫‮‭‭‭‏‬‭‮‍‬‎‫‫‍‏‪‭‪‏‎‬‬‮(String , String , MulticastDelegate )
   at ‍​‪‪‌‬‪‭‫​‬​​‌‎‪‎‭‍​‪‭‭‫‏‮‮.‌‍‮‫‬‭‏‎‍‏‏‮‌​‏‎‌‮‬‍‍​‬‌‌‎‌‏‮(Object , EventArgs )
   at System.Windows.Forms.ToolStripItem.RaiseEvent(Object key, EventArgs e)
   at System.Windows.Forms.ToolStripMenuItem.OnClick(EventArgs e)
   at System.Windows.Forms.ToolStripItem.HandleClick(EventArgs e)
   at System.Windows.Forms.ToolStripItem.HandleMouseUp(MouseEventArgs e)
   at System.Windows.Forms.ToolStripItem.FireEventInteractive(EventArgs e, ToolStripItemEventType met)
   at System.Windows.Forms.ToolStripItem.FireEvent(EventArgs e, ToolStripItemEventType met)
   at System.Windows.Forms.ToolStrip.OnMouseUp(MouseEventArgs mea)
   at System.Windows.Forms.ToolStripDropDown.OnMouseUp(MouseEventArgs mea)
   at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)
   at System.Windows.Forms.Control.WndProc(Message& m)
   at System.Windows.Forms.ScrollableControl.WndProc(Message& m)
   at System.Windows.Forms.ToolStrip.WndProc(Message& m)
   at System.Windows.Forms.ToolStripDropDown.WndProc(Message& m)
   at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
   at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
   at System.Windows.Forms.NativeWindow.DebuggableCallback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
   at MS.Win32.UnsafeNativeMethods.DispatchMessage(MSG& msg)
   at System.Windows.Threading.Dispatcher.PushFrameImpl(DispatcherFrame frame)
   at System.Windows.Threading.Dispatcher.PushFrame(DispatcherFrame frame)
   at System.Windows.Window.ShowHelper(Object booleanBox)
   at System.Windows.Window.Show()
   at System.Windows.Window.ShowDialog()
   at TRS.ViewModel.GenerateReportViewModel.OpenDialogWithoutTransformerLock(ObservableCollection`1 _TestSections) in C:\Code\TRS_Dev_Project\NewStructure\TRS.ViewModel\GenerateReportViewModel.cs:line 461
   at TRS.ViewModel.GenerateReportViewModel.GenerateReport() in C:\Code\TRS_Dev_Project\NewStructure\TRS.ViewModel\GenerateReportViewModel.cs:line 416
   at TRS.ViewModel.Command.RelayCommand.<>c__DisplayClass3_0.<.ctor>b__1(Object x) in C:\Code\TRS_Dev_Project\NewStructure\TRS.ViewModel\Command\RelayCommand.cs:line 58
   at TRS.ViewModel.Command.RelayCommand.Execute(Object parameter) in C:\Code\TRS_Dev_Project\NewStructure\TRS.ViewModel\Command\RelayCommand.cs:line 78
   at MS.Internal.Commands.CommandHelpers.CriticalExecuteCommandSource(ICommandSource commandSource, Boolean userInitiated)
   at System.Windows.Controls.Primitives.ButtonBase.OnClick()
   at System.Windows.Controls.Button.OnClick()
   at System.Windows.Controls.Primitives.ButtonBase.OnMouseLeftButtonUp(MouseButtonEventArgs e)
   at System.Windows.UIElement.OnMouseLeftButtonUpThunk(Object sender, MouseButtonEventArgs e)
   at System.Windows.Input.MouseButtonEventArgs.InvokeEventHandler(Delegate genericHandler, Object genericTarget)
   at System.Windows.RoutedEventArgs.InvokeHandler(Delegate handler, Object target)
   at System.Windows.RoutedEventHandlerInfo.InvokeHandler(Object target, RoutedEventArgs routedEventArgs)
   at System.Windows.EventRoute.InvokeHandlersImpl(Object source, RoutedEventArgs args, Boolean reRaised)
   at System.Windows.UIElement.ReRaiseEventAs(DependencyObject sender, RoutedEventArgs args, RoutedEvent newEvent)
   at System.Windows.UIElement.OnMouseUpThunk(Object sender, MouseButtonEventArgs e)
   at System.Windows.Input.MouseButtonEventArgs.InvokeEventHandler(Delegate genericHandler, Object genericTarget)
   at System.Windows.RoutedEventArgs.InvokeHandler(Delegate handler, Object target)
   at System.Windows.RoutedEventHandlerInfo.InvokeHandler(Object target, RoutedEventArgs routedEventArgs)
   at System.Windows.EventRoute.InvokeHandlersImpl(Object source, RoutedEventArgs args, Boolean reRaised)
   at System.Windows.UIElement.RaiseEventImpl(DependencyObject sender, RoutedEventArgs args)
   at System.Windows.UIElement.RaiseTrustedEvent(RoutedEventArgs args)
   at System.Windows.UIElement.RaiseEvent(RoutedEventArgs args, Boolean trusted)
   at System.Windows.Input.InputManager.ProcessStagingArea()
   at System.Windows.Input.InputManager.ProcessInput(InputEventArgs input)
   at System.Windows.Input.InputProviderSite.ReportInput(InputReport inputReport)
   at System.Windows.Interop.HwndMouseInputProvider.ReportInput(IntPtr hwnd, InputMode mode, Int32 timestamp, RawMouseActions actions, Int32 x, Int32 y, Int32 wheel)
   at System.Windows.Interop.HwndMouseInputProvider.FilterMessage(IntPtr hwnd, WindowMessage msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
   at System.Windows.Interop.HwndSource.InputFilterMessage(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
   at MS.Win32.HwndWrapper.WndProc(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
   at MS.Win32.HwndSubclass.DispatcherCallbackOperation(Object o)
   at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)
   at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Int32 numArgs, Delegate catchHandler)

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

@AmmarKhambaty

Please try the latest version of Aspose.Words for Reporting Services 19.2.

If you still face problem, please attach the following resources here for testing:

  • Your input RDL/RDLC.
  • Please create a sample application ( source code without compilation errors ) that helps us to reproduce your problem on our end and attach it here for testing.

As soon as you get these pieces of information ready, we will start investigation into your issue and provide you more information. Thanks for your cooperation.

PS: To attach these resources, please zip and upload them.

Hello,

Thanks for your reply, I am using the latest Aspose.Words for reporting Services 19.2
I have narrowed down to this specific problem.
If I remove the image from the RDLC the export export functions for Aspose start working, but with the image the export throws the exception.
Please check the attached RDLC
ReportImage2.zip (6.1 KB)

@AmmarKhambaty

We are investigating this issue and will get back to you soon.

@AmmarKhambaty

We have tested the scenario and faced different exception while exporting DOCX.

Please create and share a sample application that helps us to reproduce your problem on our end. Please also share the Visual Studio version that you are using at your end. Thanks for your cooperation.

I am using VS 2017, Attached is the solution.

@AmmarKhambaty

Unfortunately, we have not found the attachment with your post. Please ZIP and attach it. If the size of application is greater than 10MB, please share it via Dropbox. Thanks for your cooperation.

PFA the reduced size, I had to remove Aspose.Words.Reporting.Services.dll (Please
add it at your end i am using the latest version 19.2)

ReportingService_Aspose.zip (5.2 MB)

@AmmarKhambaty

We have tested the scenario and have managed to reproduce the same issue at our side. For the sake of correction, we have logged this problem in our issue tracking system as WORDSRS-273. You will be notified via this forum thread once this issue is resolved.

We apologize for your inconvenience.