如果没有框架,我的程序将无法在计算机上运行,​​我是否可以在每个Windows 2k / xp系统上运行程序? [英] my program won't work on computer without framework, dow do i make a program that runs on every windows 2k/xp system ?

查看:61
本文介绍了如果没有框架,我的程序将无法在计算机上运行,​​我是否可以在每个Windows 2k / xp系统上运行程序?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

你好,


我很抱歉,但我不明白.net环境的概念

呢。 />
我做了一个简单的程序来检索

本地计算机的主机名和ipaddress。


但是当我给你的.exe文件对我的朋友,他不能运行它,因为他确实

没有框架1.1

我认为这个框架只是一个庞大的类库/>
您可以在编码时使用,但现在我看到该程序仅适用于具有此框架的
计算机。它让我想起Java程序,它只运行在最新和配置级别的计算机上的



i想知道我如何制作windows在每台

windows 2000 / xp计算机上运行的程序。


希望你们中的一些人可以向我解释这个概念,我可能正在看看

这里有问题。


grtx,

b

解决方案

< blockquote> bart< ba ** @ thatissecret.nlm>写道:

我很抱歉,但我还不了解.net环境的概念
我做了一个简单的程序来检索主机名和本地计算机的ipaddress。

但是当我把你的.exe文件提供给我的朋友时,他不能运行它,因为他确实没有框架1.1


是的。

我认为这个框架只是一个庞大的类库,你可以在编码时使用它,但现在我看到了yhe程序仅适用于具有此框架的计算机。它让我想起了Java程序,它只运行在java最新和配置级别的计算机上。


好​​吧,Java程序可以在任何足够的Java环境中使用

用于该程序 - 如果你编写的程序只使用

Java 1.1特性,即使Java现在为1.4.2,你也可以在只有Java 1.1的机器上运行它,即
。这对于.NET来说是一样的,尽管如果你有的话,强大的版本控制会使某些东西更难以工作

在.NET 1.0和1.1上使用基于1.1的IDE进行开发。

(当你这样做时,它更有可能正常工作,但同样的原因也是如此。)

i想知道如何制作在每台Windows 2000 / xp计算机上运行的Windows程序。


基本上不要使用.NET。

希望你们中的一些人可以向我解释这个概念,我很可能在看看
这里的事情不对。




不 - 当我认为不需要时,你只是把它视为一个大问题

成为。如果您使用DirectX9功能编写程序,您是否期望

这些程序可以在没有DirectX9的机器上使用?

-

Jon Skeet - < sk *** @ pobox.com>
http:// www.pobox.com/~skeet

如果回复小组,请不要给我发邮件


Jon Jon,


有没有办法让我可以使用Visual Studio制作不需要框架dll的Windows程序?


我只是在测试制作一个简单的程序。我使用DnsGetHostname()

类来获取计算机的主机名。我可以看到这个类在框架目录中使用了

system.dll。


我可能不会将此代码(system.dll)编译成可执行文件?


bart

" Jon Skeet [C#MVP]" < SK *** @ pobox.com>在消息中写道

新闻:MP ************************ @ msnews.microsoft.c om ...

bart< ba ** @ thatissecret.nlm>写道:

我很抱歉,但我还不了解.net环境的概念
我做了一个简单的程序来检索主机名和本地计算机的ipaddress。

但是当我把你的.exe文件给我的朋友时,他不能运行它,因为他的
没有framwork 1.1



是的。

我认为这个框架只是一个庞大的类库
你可以编写代码,但是现在我看到yhe程序只适用于具有此框架的计算机。它让我想起了Java程序,只有
运行在java最新和配置级别的计算机上。



好的,Java程序可以在任何足够的Java环境中运行/>对于该程序是可用的 - 如果你编写的程序只使用了Java 1.1的功能,你可以在只有Java 1.1的机器上运行它,即使Java现在是1.4.2。对于.NET来说也是如此,尽管如果你使用基于1.1的IDE进行开发,强大的版本控制会使.NET 1.0和1.1上的某些东西更难以工作。
(当你这样做时,它更有可能正常工作,但是,正是因为同样的原因。)

我想知道我是怎么回事可以制作在每台
windows 2000 / xp计算机上运行的Windows程序。



基本上不要使用.NET。

希望你们中的一些人可以向我解释这个概念,我可能会在这里看错了。$ / blockquote>

没有 - 你只是把它视为一个大的当我认为不需要它时,问题就出现了。如果您使用DirectX9功能编写程序,您是否希望这些程序在没有DirectX9的机器上可用?
-
Jon Skeet - < sk *** @ pobox.com> ;
http://www.pobox.com/~skeet
如果回复小组,请不要给我发邮件



bart< ba ** @ thatissecret.nlm>写道:

有没有办法可以使用Visual Studio制作不需要框架dll的Windows程序?


是 - 但只能编写非托管C ++。

我只是在测试制作一个简单的程序。我使用DnsGetHostname()
类来获取计算机的主机名。我可以看到这个类使用了框架目录中的
system.dll。

我可以不将此代码(system.dll)编译成可执行文件吗?




不,因为它不仅仅是它使用库的情况 - .NET是一个完整的虚拟执行环境,而不仅仅是一组库。


-

Jon Skeet - < sk *** @ pobox.com>
http://www.pobox.com/~skeet

如果回复该群组,请不要给我发邮件


Hello,

I''m so sorry, but i don''t understand the concept of the .net environment
yet.
I made a simple program that retrieves the hostname and ipaddress of the
local computer.

But when i give thit .exe file to my friend he can''t run it because he does
not have the framwork 1.1
I thought that the this framework is just a large library of classes wich
you can you when coding, but now i see that yhe program only works on
computers with this framework. it reminds me of Java programs wich only runs
at computers where the java is at latest and configured level.

i would like to know how i can make windows programs that run on every
windows 2000/xp computer.

hope some of you can explain me the concept, i am probably doing ans seeing
things wrong here.

grtx,
b

解决方案

bart <ba**@thatissecret.nlm> wrote:

I''m so sorry, but i don''t understand the concept of the .net environment
yet.
I made a simple program that retrieves the hostname and ipaddress of the
local computer.

But when i give thit .exe file to my friend he can''t run it because he does
not have the framwork 1.1
Yup.
I thought that the this framework is just a large library of classes wich
you can you when coding, but now i see that yhe program only works on
computers with this framework. it reminds me of Java programs wich only runs
at computers where the java is at latest and configured level.
Well, Java programs will work wherever a sufficient Java environment
for that program is available - if you write a program which only uses
Java 1.1 features, you can run that on a machine with only Java 1.1,
even though Java is now at 1.4.2. It''s the same for .NET, although
stronger versioning makes it slightly harder to get something to work
on both .NET 1.0 and 1.1 if you''re developing with a 1.1-based IDE.
(It''s more likely to work properly when you do, however, for precisely
the same reason.)
i would like to know how i can make windows programs that run on every
windows 2000/xp computer.
Don''t use .NET, basically.
hope some of you can explain me the concept, i am probably doing ans seeing
things wrong here.



Nope - you''re just seeing it as a big issue when I don''t think it needs
to be. If you wrote programs using DirectX9 features, would you expect
those programs to be available on machines without DirectX9 on them?
--
Jon Skeet - <sk***@pobox.com>
http://www.pobox.com/~skeet
If replying to the group, please do not mail me too


Hi Jon,

Is there a way i could use Visual Studio to make Windows programs that don''t
require the framework dll''s ?

I was just testing to make a simple program. I used the DnsGetHostname()
class to get the hostname the computer. I could see that this class uses the
system.dll in the framework directory.

could i just not compile this code (system.dll) into the executable ?

bart
"Jon Skeet [C# MVP]" <sk***@pobox.com> wrote in message
news:MP************************@msnews.microsoft.c om...

bart <ba**@thatissecret.nlm> wrote:

I''m so sorry, but i don''t understand the concept of the .net environment
yet.
I made a simple program that retrieves the hostname and ipaddress of the
local computer.

But when i give thit .exe file to my friend he can''t run it because he does not have the framwork 1.1



Yup.

I thought that the this framework is just a large library of classes wich you can you when coding, but now i see that yhe program only works on
computers with this framework. it reminds me of Java programs wich only runs at computers where the java is at latest and configured level.



Well, Java programs will work wherever a sufficient Java environment
for that program is available - if you write a program which only uses
Java 1.1 features, you can run that on a machine with only Java 1.1,
even though Java is now at 1.4.2. It''s the same for .NET, although
stronger versioning makes it slightly harder to get something to work
on both .NET 1.0 and 1.1 if you''re developing with a 1.1-based IDE.
(It''s more likely to work properly when you do, however, for precisely
the same reason.)

i would like to know how i can make windows programs that run on every
windows 2000/xp computer.



Don''t use .NET, basically.

hope some of you can explain me the concept, i am probably doing ans seeing things wrong here.



Nope - you''re just seeing it as a big issue when I don''t think it needs
to be. If you wrote programs using DirectX9 features, would you expect
those programs to be available on machines without DirectX9 on them?
--
Jon Skeet - <sk***@pobox.com>
http://www.pobox.com/~skeet
If replying to the group, please do not mail me too



bart <ba**@thatissecret.nlm> wrote:

Is there a way i could use Visual Studio to make Windows programs that
don''t require the framework dll''s ?
Yes - but only by writing unmanaged C++.
I was just testing to make a simple program. I used the DnsGetHostname()
class to get the hostname the computer. I could see that this class uses the
system.dll in the framework directory.

could i just not compile this code (system.dll) into the executable ?



No, because it''s not just a case of it using a library - .NET is a
whole virtual execution environment, not just a set of libraries.

--
Jon Skeet - <sk***@pobox.com>
http://www.pobox.com/~skeet
If replying to the group, please do not mail me too


这篇关于如果没有框架,我的程序将无法在计算机上运行,​​我是否可以在每个Windows 2k / xp系统上运行程序?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆