-
May 26th, 2013, 02:47 PM
#1
c# code not executing
Hello People!
I have been having a very hard time trying to run a piece of code that I downloaded. I thought it would be best to take a screenshot of it so people can help.
Can someone please tell me how I can overcome this problem and get it running please.
-
May 26th, 2013, 03:04 PM
#2
Re: c# code not executing
Just follow the instructions given in the dialog i.e. add an executable to the project.
-
May 26th, 2013, 03:27 PM
#3
Re: c# code not executing
Originally Posted by S_M_A
Just follow the instructions given in the dialog i.e. add an executable to the project.
Hi SMA. I'm a beginner in c# but I want to see this code in action. How do I add an executable to the project?
Again sorry this is very trivial for you.
-
May 26th, 2013, 03:31 PM
#4
Re: c# code not executing
Right-click on your solution (in the solution explorer), select add new project and make that project be an exe project (console or form). From the new project call/use what's public in your class library.
Edit: Oh! Now I see that you have a main in your code so your project is probably just set up wrong. Select properties instead and in Application change the project type to console.
Last edited by S_M_A; May 26th, 2013 at 03:42 PM.
-
May 26th, 2013, 03:34 PM
#5
Re: c# code not executing
Originally Posted by S_M_A
Right-click on your solution (in the solution explorer), select add new project and make that project be an exe project (console or form). From the new project call/use what's public in your class library.
Hi. I clicked on 'Start as new project' but this comes up when I execute it:
'GATest.vshost.exe' (Managed (v2.0.50727)): Loaded 'C:\Windows\assembly\GAC_64\mscorlib\2.0.0.0__b77a5c561934e089\mscorlib.dll'
'GATest.vshost.exe' (Managed (v2.0.50727)): Loaded 'C:\Windows\assembly\GAC_MSIL\Microsoft.VisualStudio.HostingProcess.Utilities\11.0.0.0__b03f5f7f11d50a3a\Microsoft.VisualStudio.HostingProcess.Utilities.dll'
'GATest.vshost.exe' (Managed (v2.0.50727)): Loaded 'C:\Windows\assembly\GAC_MSIL\System.Windows.Forms\2.0.0.0__b77a5c561934e089\System.Windows.Forms.dll'
'GATest.vshost.exe' (Managed (v2.0.50727)): Loaded 'C:\Windows\assembly\GAC_MSIL\System\2.0.0.0__b77a5c561934e089\System.dll'
'GATest.vshost.exe' (Managed (v2.0.50727)): Loaded 'C:\Windows\assembly\GAC_MSIL\System.Drawing\2.0.0.0__b03f5f7f11d50a3a\System.Drawing.dll'
'GATest.vshost.exe' (Managed (v2.0.50727)): Loaded 'C:\Windows\assembly\GAC_MSIL\Microsoft.VisualStudio.HostingProcess.Utilities.Sync\11.0.0.0__b03f5f7f11d50a3a\Microsoft.VisualStudio.HostingProcess.Utilities.Sync.dll'
'GATest.vshost.exe' (Managed (v2.0.50727)): Loaded 'C:\Windows\assembly\GAC_MSIL\Microsoft.VisualStudio.Debugger.Runtime\11.0.0.0__b03f5f7f11d50a3a\Microsoft.VisualStudio.Debugger.Runtime.dll'
'GATest.vshost.exe' (Managed (v2.0.50727)): Loaded 'C:\Users\Imran\Desktop\btl_GA2\GATest\bin\Debug\GATest.vshost.exe'
'GATest.vshost.exe' (Managed (v2.0.50727)): Loaded 'C:\Windows\assembly\GAC_64\System.Data\2.0.0.0__b77a5c561934e089\System.Data.dll'
'GATest.vshost.exe' (Managed (v2.0.50727)): Loaded 'C:\Windows\assembly\GAC_MSIL\System.Xml\2.0.0.0__b77a5c561934e089\System.Xml.dll'
The thread 'vshost.NotifyLoad' (0x2fa8) has exited with code 0 (0x0).
The thread 'vshost.LoadReference' (0x2a28) has exited with code 0 (0x0).
'GATest.vshost.exe' (Managed (v2.0.50727)): Loaded 'C:\Users\Imran\Desktop\btl_GA2\GATest\bin\Debug\GATest.exe', Symbols loaded.
'GATest.vshost.exe' (Managed (v2.0.50727)): Loaded 'C:\Users\Imran\Desktop\btl_GA2\GATest\bin\Debug\GeneticAlgorithm.dll', Symbols loaded.
The thread 'vshost.RunParkingWindow' (0x2a70) has exited with code 0 (0x0).
The thread '<No Name>' (0x27ec) has exited with code 0 (0x0).
The program '[9592] GATest.vshost.exe: Managed (v2.0.50727)' has exited with code 0 (0x0).
The program '[9592] GATest.vshost.exe: Program Trace' has exited with code 0 (0x0).
-
May 26th, 2013, 03:38 PM
#6
Re: c# code not executing
Thank you very much sma - it worked!
-
May 26th, 2013, 03:46 PM
#7
Re: c# code not executing
That output isn't anything to be worried about. It's just informing you what other code that is loaded when you execute your application.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|