Linux 中的 Visual Basic .Net

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/6067894/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-08-05 04:09:41  来源:igfitidea点击:

Visual Basic .Net in Linux

linuxvb.net

提问by Sandhya Jha

Is it possible to run Visual Basic .Netin Linux?

是否可以在 Linux 中运行Visual Basic .Net

I have written code in Visual basic and compiled it as well using Visual Studio in Windows.

我已经用 Visual Basic 编写了代码,并在 Windows 中使用 Visual Studio 对其进行了编译。

Can the same code be written (and compiled) in Linux as well?

是否也可以在 Linux 中编写(和编译)相同的代码?

If yes, then which software do I need to install on Linux?

如果是,那么我需要在 Linux 上安装哪些软件?

Is the Linux alternative of Visual basic freeware?

Linux 是 Visual Basic 免费软件的替代品吗?

采纳答案by GolezTrol

There are a few, like SimpleBasic, GnomeBasic and XBasic. None of them are fully compatible with Visual Basic.

有一些,如 SimpleBasic、GnomeBasic 和 XBasic。它们都不与 Visual Basic 完全兼容。



The above answer was accepted eons ago, but is horribly outdated, since more recently, there's also .Net Core. This willrun the actual VB.Net language, but will notuse WinForms controls and features powering most real VB.Net apps. .NET Core 3 does support some variation of WinForms, but only on Windows.

上面的答案在亿万年前就被接受了,但已经过时了,因为最近还有 .Net Core。这运行实际的 VB.Net 语言,但不会使用支持大多数真实 VB.Net 应用程序的 WinForms 控件和功能。.NET Core 3 确实支持WinForms 的一些变体,但仅在 Windows 上。

Please check Pedro Polonia's excellent answer that contains all the details that mine misses.

请查看Pedro Polonia的优秀答案,其中包含我遗漏的所有细节。

回答by Mat

You could have a look at the Mono VisualBasic.Net support, or maybe go and check out the Gambasproject.

你可以看看Mono VisualBasic.Net support,或者去看看Gambas项目。

You won't find a fully compatible solution.

您不会找到完全兼容的解决方案。

回答by Orlando Herrera

Mono is a really interesting project. You can run applications on Linux. Is not fully compatible, but they are working on that.

Mono 是一个非常有趣的项目。您可以在 Linux 上运行应用程序。不完全兼容,但他们正在努力。

Take a look in this site Working with Mono

看看这个站点使用 Mono

回答by kees broeksma

VB on linux is posible using vb2005.
First install wine.
run in the terminal winetricks dotnet20 dotnet40
download the installer and run it
(wine Downloads/yourinstaller.exe)
execute wine WINEPREFIX=~/yourprefix WINEARCH='win32' wine yourprefix/drive_c/Program\ Files/Microsoft\ Visual\ Studio\ 8/Common7/IDE/vbexpress.exe

linux 上的 VB 可以使用 vb2005。
首先安装wine。
在终端中运行winetricks dotnet20 dotnet40
下载安装程序并运行
(wine Downloads/yourinstaller.exe)
执行wine WINEPREFIX=~/yourprefix WINEARCH='win32' wine yourprefix/drive_c/Program\ Files/Microsoft\ Visual\ Studio\ 8/Common7/IDE/vbexpress.exe

回答by Pedro Polonia

You can run Visual Basic, Visual Basic.net, C# code and applications on Linux.

您可以在 Linux 上运行 Visual Basic、Visual Basic.net、C# 代码和应用程​​序。

The most popular .net IDE is Visual Studio(now in version 2019) that runs in Windows and Mac Os. A good alternative for Linux users is Visual Studio Code(runs in Linux, Windows and Mac)

最流行的 .net IDE 是在 Windows 和 Mac Os 中运行的Visual Studio(现在是 2019 版)。对于 Linux 用户来说,一个不错的选择是Visual Studio Code(在 Linux、Windows 和 Mac 上运行)

You can compile and run Visual Basic .net code and applications (part of .net framework, consider the successor of Visual Basic, with several language differences from vb6). An subset of .net is .Net Corethat can be install on

您可以编译和运行 Visual Basic .net 代码和应用程​​序(.net 框架的一部分,考虑 Visual Basic 的后继者,与 vb6 有一些语言差异)。.net 的一个子集是可以安装的.Net Core

  • Red Hat,
  • Ubunto,
  • Mint,
  • Debian,
  • Fedora,
  • CentOs,
  • Oracle Linux
  • and openSUSE Linux distritutions.
  • 红帽,
  • 乌本托,
  • 薄荷,
  • Debian,
  • 软呢帽,
  • CentO,
  • 甲骨文Linux
  • 和 openSUSE Linux 发行版。

Setup details on https://www.microsoft.com/net/core

https://www.microsoft.com/net/core 上的设置详细信息

You can also use Mono, a free and open-source project led by Xamarin (a subsidiary of Microsoft) and the.NET Foundation. The project focus is to support an Ecma standard-compliant .NET Framework-compatible set of tools (including a C# compiler and a Common Language Runtime).

您还可以使用Mono,这是一个由 Xamarin(Microsoft 的子公司)和 .NET Foundation 领导的免费开源项目。该项目的重点是支持符合 Ecma 标准的 .NET Framework 兼容工具集(包括 C# 编译器和公共语言运行时)。

Mono can be installedon

Mono 可以安装

  • Ubunto,
  • Debian,
  • Raspbian (used in Raspberry pi)
  • and CentOs Linux distritutions.
  • 乌本托,
  • Debian,
  • Raspbian(用于树莓派)
  • 和 CentOs Linux 发行版。

You can run most windows applications (created with VB, Vb.net or with other tools) using winethat supports windows API on Linux.

您可以在 Linux 上使用支持 windows API 的wine运行大多数 windows 应用程序(使用 VB、Vb.net 或其他工具创建)。

** About Visual Basic (not VB.net, due to original question) **

** 关于 Visual Basic(不是 VB.net,由于原始问题)**

Note that the last version of visual basic is 6.0, realeased in 1998, declared legacy during 2008 and supported on Windows XP, Vista, Windows Server 2008 including R2, Windows 7, Windows Server 2012, and Windows 8.x. There are also other basic flavors (like quick basic, Gambasor others)

请注意,visual basic 的最新版本是 6.0,于 1998 年发布,2008 年宣布为旧版本,支持 Windows XP、Vista、Windows Server 2008(包括 R2、Windows 7、Windows Server 2012 和 Windows 8.x)。还有其他基本口味(如快速基本Gambas或其他)

The support end dates for Visual Basic 6.0are:

Visual Basic 6.0 的支持结束日期是:

  • The Visual Basic 6.0 IDE [Integrated Development Environment]: supported ended on April 8, 2008.
  • Visual Basic 6.0 Runtime the base libraries and execution engine used to run VB6 applications: support ended on April 8, 2014.
  • Visual Basic 6.0 Runtime Extended Files: support ended on April 8, 2014.
  • Visual Basic 6.0 IDE [集成开发环境]:支持于 2008 年 4 月 8 日结束。
  • Visual Basic 6.0 Runtime 用于运行 VB6 应用程序的基础库和执行引擎:支持于 2014 年 4 月 8 日结束。
  • Visual Basic 6.0 运行时扩展文件:支持于 2014 年 4 月 8 日结束。

回答by Peter Bauer

Gambas Basic is activly developed and works good. Here you can find a small Tutorial for programming a calculator.

Gambas Basic 得到了积极开发并且运行良好。在这里你可以找到一个计算器编程的小教程。

https://www.bitkistl.com/2020/02/gambas-basic-314.html

https://www.bitkistl.com/2020/02/gambas-basic-314.html