Skip to content

System.Runtime.InteropServices.COMException (0x8000001D): Activating a single-threaded class from MTA is not supported (Exception from HRESULT: 0x8000001D) #49

@rffrasca

Description

@rffrasca

Describe the bug
Regression bug from the conversion of the remaining VB.NET code to C# that was completed in v10.0.0. The unhandled exception is being thrown after Copy PDF to Clipboard has been selected.

To Reproduce
Steps to reproduce the behavior:

  1. Select the document in the Documents list
  2. Click File menu
  3. Click Copy PDF to Clipboard
  4. See error

Expected behavior
PDF for selected item should be copied to the Windows Clipboard.

Screenshots
image

Desktop (please complete the following information):

  • PDFKeeper Version: 10.0.0 - 11.0.0

Additional context
System.Runtime.InteropServices.COMException (0x8000001D): Activating a single-threaded class from MTA is not supported (Exception from HRESULT: 0x8000001D)
at System.StubHelpers.StubHelpers.GetWinRTFactoryObject(IntPtr pCPCMD)
at Windows.ApplicationModel.DataTransfer.Clipboard.SetContent(DataPackage content)
at PDFKeeper.Core.FileIO.PDF.PdfFile.d__21.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
at System.Threading.QueueUserWorkItemCallback.System.Threading.IThreadPoolWorkItem.ExecuteWorkItem()
at System.Threading.ThreadPoolWorkQueue.Dispatch()

Metadata

Metadata

Assignees

Labels

Projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions