running C# program
CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 8 of 8

Thread: running C# program

  1. #1
    Join Date
    Aug 2001
    Location
    New Orleans, Louisiana
    Posts
    98

    running C# program

    From what I have heard about this language you must have C# loaded on a machine to run a program written in C#. (i.e. it is like Java) is this true, or does it generate an executable that can be run on a machine without C#???????

  2. #2
    Join Date
    Jan 2002
    Location
    Mumbai, Maharashtra, India
    Posts
    13

    Re: running C# program

    Yeah ! It is like java. Any program in any .NET language starts with loading the CLR, which is in mscorlib.dll. So firstly this should be there on ur system. Secondly, all the dlls form which u r using ur namespaces in ur assembly folder in WINNT.

    SO u've to download the runtime from MS site.

  3. #3
    Join Date
    May 2002
    Location
    Atlanta,GA
    Posts
    262

    Re: running C# program

    Originally posted by ncs
    From what I have heard about this language you must have C# loaded on a machine to run a program written in C#. (i.e. it is like Java) is this true, or does it generate an executable that can be run on a machine without C#???????
    The machine must be loaded with the CLR ( common language runtime). This is the equivalent of the JVM. Unlike the JVM though, the CLR can run any managed application (VB, C# etc).

    You can use tools like ngen to precompile your IL code into the architecture of your choice but I believe you still need a lot of the DLL's that come with the CLR to run your applications.
    Jared

  4. #4
    Join Date
    Oct 2001
    Location
    Norway
    Posts
    265
    ngen.exe will only affect startup times. You will still need the whole CLR to run the assembly. You will also need the original assemblies present on disk, since the CLR requires these for metadata. An ngen'ed image does not contain any metadata by itself.

  5. #5
    Join Date
    May 2002
    Posts
    121
    Is there a way to package the program into an installation file that will take care of the nuisance?

    How can I make an installation file, like with vb5?

  6. #6
    Join Date
    Apr 2001
    Location
    Midwest
    Posts
    57
    I haven't used it myself yet, but try
    File->New->Project->Setup and Deployment Projects for a start...
    "Judge a man by his questions rather than his answers." - Voltaire

  7. #7
    Join Date
    May 2002
    Posts
    121
    err...
    Where do I start?
    I want to create a setup app for my (c#)solution.

  8. #8
    Join Date
    Jun 2002
    Location
    SW FLorida
    Posts
    8
    dky1e:

    sternaphile wrote:


    I haven't used it myself yet, but try File->New->Project->Setup and Deployment Projects for a start...

    ... which I believe presumed that you are using the C# .NET IDE, which would open the New Project wizard for you.

    You could then select 'Visual C# Projects' from the Project Types frame, and either 'Windows Application' or 'ASP .NET Web Application' from the Templates frame.

    Hope this helps,

    JimH
    Doin' the Shift-Click Drag ....

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


Windows Mobile Development Center


Click Here to Expand Forum to Full Width

This is a CodeGuru survey question.


Featured


HTML5 Development Center