Coder Social home page Coder Social logo

pa-0 / runnet Goto Github PK

View Code? Open in Web Editor NEW

This project forked from mobzystems/runnet

0.0 0.0 0.0 13 KB

Use VB.NET and C# as a scripting language! Run .NET 'code snippets' as console applications without generating an executable file on disk

Home Page: https://www.mobzystems.com/tools/runnet/

Visual Basic 92.19% C# 7.81%

runnet's Introduction

RunNET

In a nutshell: RunNET takes a .NET source code file (C# or VB.NET or whatever you have installed on your machine) and runs it as a console application. This is what RunNET itself shows when run without arguments:

RunNET: RunNET v1.0.0 (64-bit)
Copyright (C) MOBZystems, 2011
http://www.mobzystems.com/tools/runnet

Run .NET code as a console application.

Usage: RunNET [/v] source.ext [arg [arg ...]]
Options:
  /v  - verbose (show result of call to Program.Main and exit code)
  /l  - show supported languages and extensions on this computer
source.ext   - source code to run. Extensions must be a valid extension for the language used.
               The static/Shared method Main() in the public class Program is called,
               and its result is returned as exit code for RunNET.
               Main() must return an int/Integer, or return void/be a Sub.
               It must accept no arguments, or an array of string, specifying arguments
arg          - argument(s) passed to Program.Main()

The source code must contain a Program class with a Main method. e.g.:

// This is the minimal skeleton of a program that
// can be run using RunNET: a Program class
// with a Main method

using System;

public class Program
{
  // This method should be declared as: 
  //
  // Main(string arguments[])
  //
  // or
  //
  // Main()
  //
  // The return type can be void or int
  public static int Main()
  {
    Console.WriteLine("Hello world from C#!");
    // Use
    // RunNET /v test.cs
    // to see the exit code, in this case 1234
    return 1234;
  }
}

See the source code for more examples.

For more documentation and samples, please visit MOBZystems, Home of Tools

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.