question

khakindrad1 avatar image
0 Votes"
khakindrad1 asked DanielZhang-MSFT commented

This operation returned because the timeout period expired. (Exception from HRESULT: 0x800705B4)

While executing following code exception occurred at production environment.
CompilerResults cr = provider.CompileAssemblyFromSource(cp, code.ToString());
35676-image.png
Exception Details:-
Message: This operation returned because the timeout period expired. (Exception from HRESULT: 0x800705B4)
StackTrace:
at System.Reflection.RuntimeAssembly.nLoadImage(Byte[] rawAssembly, Byte[] rawSymbolStore, Evidence evidence, StackCrawlMark& stackMark, Boolean fIntrospection, SecurityContextSource securityContextSource)
at System.Reflection.Assembly.Load(Byte[] rawAssembly, Byte[] rawSymbolStore, Evidence securityEvidence)
at Microsoft.CSharp.CSharpCodeGenerator.FromFileBatch(CompilerParameters options, String[] fileNames)
at Microsoft.CSharp.CSharpCodeGenerator.FromSourceBatch(CompilerParameters options, String[] sources)
at Microsoft.CSharp.CSharpCodeGenerator.System.CodeDom.Compiler.ICodeCompiler.CompileAssemblyFromSourceBatch(CompilerParameters options, String[] sources)


windows-forms
image.png (53.9 KiB)
· 4
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

Hello, are you using UWP for development, if not, please change tag to the corresponding product, here is the list of supported products? If so, can you provide more code snippets and steps to reproduce so that we can reproduce this problem?

0 Votes 0 ·

Hi Richard,
Thanks for your reply.
Actually i'm facing the issue in Windows Forms Application so changing the tag to Windows-Forms.

0 Votes 0 ·

Does it happen on first run or after other many executions of this fragment?

0 Votes 0 ·

It occurred on Production today and same is working fine after restart the application.

0 Votes 0 ·

1 Answer

DanielZhang-MSFT avatar image
0 Votes"
DanielZhang-MSFT answered DanielZhang-MSFT commented

Hi Khakindra Devkota,
Based on the error description, I suggest you perform a clean boot.
Please follow the steps below:
1. Open Run window by pressing the Windows + R key at a time
2. In the run box type msconfig in the search field and hit Enter
3. Click on the services tab
4. Now make sure to tick on Hide all Microsoft services
5. Finally, click on Disable all button
6. Restart your System and check if the error still occurs
More details you can refer to this document.
Best Regards,
Daniel Zhang


If the response is helpful, please click "Accept Answer" and upvote it.

Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.


· 2
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

Hi Daniel Zhang,
Thanks for your reply.
Issue is not simulating every time and same is working fine after restart my application.
I want to know the exact reason of the issue so i can fix the same.

0 Votes 0 ·

Hi @khakindrad1,
The windows-forms tag is discussing and asking questions about the Windows Forms such as Winforms controls, libraries, samples, publication and installation.
This is a rare situation that I cann't reproduce. So it is recommended to report a problem on the Developer Community and you can get more professional answer.
Thank you for your understanding.
Best Regards,
Daniel Zhang


0 Votes 0 ·