Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7015193
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T22:37:12+00:00 2026-05-27T22:37:12+00:00

I have a piece of code which uses CodeDom to generate code on the

  • 0

I have a piece of code which uses CodeDom to generate code on the fly. It’s straight forward:

  • CodeCompileUnit is created and filled with a type.
  • The unit is passed to CSharpCodeProvider.CompileAssemblyFromDom.
  • The assembly is generated in memory and everything is wrapped inside a single static method, which returns an instance of the generated type.

If I call this static method from C#, everything works fine, but it fails if I call the method from IronPython. There are no compile errors and CompiledAssembly of the returned CompilerResults is NOT null. But if I call GetTypes for the assembly, I get a ReflectionTypeLoadException which tells me to look at the LoaderExceptions. That one is a FileNotfoundException giving the following message:

Could not load file or assembly ‘PosData, Version=1.0.0.0,
Culture=neutral, PublicKeyToken=null’ or one of its dependencies. The
system cannot find the file specified.”:”PosData, Version=1.0.0.0,
Culture=neutral, PublicKeyToken=null

PosData is my own assembly which holds the code generation stuff and which is already loaded by IronPython. Everything is in a single folder, so I don’t see what might be missing.

Any hint would be very appreciated!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-27T22:37:12+00:00Added an answer on May 27, 2026 at 10:37 pm

    You could give the Fusion Log Viewer a shot to get more information about what’s going.

    See Scott Hanselman’s blog entry and this page on MSDN for details on how to use it.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a piece of code in ANSI C which uses the time.h library
I have the following piece of code which uses ICU macros in order to
I have the following piece of code which uses the ALAssets library to store
I have found the following piece of code which uses XmlHttpRequest to read JSON
I have written a piece of code which uses the PdfSharp library. The instance
I have written a piece of code which uses System.ServiceModel.Syndication library to parse RSS
I have some code which uses System.Net.Mail.SmtpClient.Send to send data from a piece of
I have this piece of code which I'm hoping will be able to tell
I am somewhat new to R, and i have this piece of code which
I have the following piece of code which replaces template markers such as %POST_TITLE%

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.