Cheat Engine Forum Index Cheat Engine
The Official Site of Cheat Engine
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 


[c#][Error]Dynamic compiling at runetime.

 
Post new topic   Reply to topic    Cheat Engine Forum Index -> General programming
View previous topic :: View next topic  
Author Message
NINTENDO
Grandmaster Cheater Supreme
Reputation: 0

Joined: 02 Nov 2007
Posts: 1371

PostPosted: Mon Mar 08, 2010 2:52 pm    Post subject: [c#][Error]Dynamic compiling at runetime. Reply with quote

So a while ago I learned how to compile programs at runetime. And it works really good for a console application. But I wan't to do a forms app. Is it much different?

This is a piece of the code I use :
Code:

         private void Compile(string Output)
        {

            CompilerParameters parameters = new CompilerParameters();
            parameters.ReferencedAssemblies.Add("System.Windows.Forms.dll");
            parameters.ReferencedAssemblies.Add("System.ComponentModel.dll");

           

            parameters.GenerateExecutable = true;
            parameters.OutputAssembly = Output;

            AddSource(GenerateForm());
            AddSource(GenerateDesginer());

            CompilerResults results = codeProvider.CompileAssemblyFromSource(parameters, SourceList.ToArray());



Untitled.png
 Description:
 Filesize:  191.13 KB
 Viewed:  4330 Time(s)

Untitled.png



_________________
Intel over amd yes.
Back to top
View user's profile Send private message Send e-mail AIM Address Yahoo Messenger MSN Messenger
Odecey
Master Cheater
Reputation: 1

Joined: 19 Apr 2007
Posts: 259
Location: Scandinavia

PostPosted: Tue Mar 09, 2010 3:25 am    Post subject: Reply with quote

As far as I know, System.Component.dll does not exist. I think the System.Component namespace can be found in System.dll.

Edit: By the way, you can find which assembly a certain namespace belongs to by going into the object browser(View->Other Windows->Object Browser) and searching for it. Then select it from the list that appears, and click on the link down to the right which says
Code:
Namespace namespacenamehere
Member of assemblynamehere
. The text will update, showing the path to the assembly.
_________________
Never confuse activity with productivity. You can be busy without a purpose, but what's the point?- Rick Warren
Back to top
View user's profile Send private message MSN Messenger
NINTENDO
Grandmaster Cheater Supreme
Reputation: 0

Joined: 02 Nov 2007
Posts: 1371

PostPosted: Tue Mar 09, 2010 11:39 am    Post subject: Reply with quote

Odecey wrote:
As far as I know, System.Component.dll does not exist. I think the System.Component namespace can be found in System.dll.

Edit: By the way, you can find which assembly a certain namespace belongs to by going into the object browser(View->Other Windows->Object Browser) and searching for it. Then select it from the list that appears, and click on the link down to the right which says
Code:
Namespace namespacenamehere
Member of assemblynamehere
. The text will update, showing the path to the assembly.

Thanks. I have a greater understanding on how .net works now Smile

_________________
Intel over amd yes.
Back to top
View user's profile Send private message Send e-mail AIM Address Yahoo Messenger MSN Messenger
SBAOM
Newbie cheater
Reputation: 0

Joined: 10 Feb 2010
Posts: 19

PostPosted: Tue Mar 09, 2010 1:27 pm    Post subject: Reply with quote

Hey this whole thing sounds interesting... could you please briefly explain what is it that you are doing?? Thank you.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    Cheat Engine Forum Index -> General programming All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group

CE Wiki   IRC (#CEF)   Twitter
Third party websites