Skip to content
| Marketplace
Sign in
Visual Studio Code>Other>C# Project OpenerNew to Visual Studio Code? Get it now.
C# Project Opener

C# Project Opener

banl

|
11 installs
| (0) | Free
Find the nearest .csproj from the current file, generate a .sln if needed, and open it in C# Dev Kit
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

C# Project Opener

Open the nearest .csproj as a solution in VS Code — no need to manually create or maintain .sln files.

How It Works

  1. From any open file, the extension walks up the directory tree to find the nearest .csproj
  2. If a fresh .sln file already exists (less than 24 hours old), it reuses it
  3. Otherwise, it generates a new .sln using slngen
  4. Opens the solution in C# Dev Kit for full IntelliSense, debugging, and project-aware features

Usage

  1. Open any file inside a C# project
  2. Run the command C#: Open Nearest Solution from the Command Palette (Ctrl+Shift+P)

Tip: Bind it to a keyboard shortcut for quick access.

Requirements

  • slngen — the extension will prompt you to install it if not found:
    dotnet tool install --global Microsoft.VisualStudio.SlnGen.Tool
    
  • C# Dev Kit (optional, for opening the solution directly)

Why?

Large C# codebases often don't have a single .sln that covers every project, and creating one manually is tedious. This extension lets you jump straight from any file to a working solution with full IDE support — just one command.


This extension was developed with AI assistance (Claude Opus 4.6).

  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
© 2026 Microsoft