分享
 
 
 

[译]关于“经典VB”的一些想法

王朝c#·作者佚名  2006-12-17
窄屏简体版  字體: |||超大  

最近,这个主题已经出现在了“新闻组”里(呃,至少已经出现在了很多blog里),我一直在考虑如何回复大家……但事实上,我根本没有回复的必要,因为Dave Totzke已经替我这么做了。他在文中提到了一点:我们应该让C++继续存在下去,是因为Office是用C++写成的……关于这点我不太敢恭维,因为这理由实际上应当是——这个被托管的世界无法取代我们为底层的硬件和操作系统编写本地代码的需要。我们至少需要一种方案,使图形软件、设备驱动器、网络信息过滤器等等都能高效地运作……因此,我们还是需要非托管的C++。但对于VB6的变革而言,就没有类似的需要了。

确实,升级复杂的代码库是件相当困难的事,但是安装VB.NET并不意味着你必须删除VB6。你可以保持你现有的代码库,而在.NET里编写新的代码,然后在必要的时候让这两个世界互相运作。在MSDN里,你可以找到一个Access应用程序,当你点击某些特定的按钮时,它会弹出新窗体来……你也可以找到为Outlook和Word写的基于VB6的插件,其实它们就是.NET代码的包装材料,是个VB6代码和VB.NET代码的混合品。

还有很多东西,它们可以在VB6里找到,却没有被包含在VB.NET里,我觉得这样不太好,但我想,它们可以通过.NET组件、ActiveX组件、或者是Visual Studio插件的形式引入VB.NET。譬如说DDE(动态数据交换,涕淌注)吧,它本身并不是.NET框架的一部分,因此,我设想如果能有一个小组件,使我们在.NET中能直接访问DDE,在新数据到达时能够引发事件,诸如此类的……那就好多了。我真希望人们能致力于构建(或者是致力于请求构建)这样的组件,而不是拼命叫嚣着做某某事不是个好主意。至少至少,人们也应该努力使它被列进升级开发的进程中。我们最好能让某个人来构建这样的一个工具,这个工具不仅仅是一个向导,而是能胜任升级的工作,并且包含了一大堆附加的库,藉此来转换旧的代码。这将会是个浩大的工程,但是比起对VB6做一些补充性的改进而言,它的成果会更令人满意的。

顺便提一句,我一直都想告诉大家,我真的认为,.NET世界中至今仍然缺少了一些东西。我们需要为.NET提供一个类似 Access界面那样的工具……它不能像VB6里的那个工具,因为它对于我眼中的开发人员的水平而言,实在是太难用了……它应该是一个支持数据库拖放的应用程序创建工具,像Access、FileMaker Pro、Hypercard,等等那样的……它应该能在这些设置背后自动生成.NET代码,这样,我们就可以使用这个工具,配合着由VB.NET或C#创建的代码,来扩展简单的应用程序。我想我会给它起个名字,Access.NET :)

@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@

以下是原文供网友们参考,如果大家要到Duncan先生的主页上读文,请点击这里。

This topic has been in the 'news' lately (well, at least in the blogs) and I've been considering replying.... but it turns out I don't have to, because Dave Totzke has done it for me. I don't really agree with his comment that we've kept C++ alive because Office is written in it... it is actually because the managed world doesn't replace the need to write native code against the underlying hardware and OS. We need to have at least one avenue for folks to write the high-performance graphic software, device drivers, network packet filters, etc.... so we need unmanaged C++ to stay. There isn't a similar need for new development on VB6.

Yes, it is hard to upgrade complex code bases, but when you install VB.NET it doesn't uninstall your copy of VB6. It is possible to maintain an existing code base while you write new code in .NET and then interop as necessary between the two worlds. Within MSDN, we have Access applications that pop-up Windows Forms when you click certain buttons... we have VB6-based add-ins for Outlook and Word that are simple wrappers around .NET code and some that are a mix of VB6 code and VB.NET code...

There are some things that were in VB6 and are not available in VB.NET that I feel still need to be available, but I think they could be made available as .NET components, ActiveX components, or add-ins to Visual Studio. Take DDE for example, it just isn't part of the .NET Framework, so I think it would be nice if we had a small component that allowed me to access DDE from within .NET, fired events when new data arrived, etc... I wish that people would put their effort towards building/requesting these types of components instead of advocating something that just isn't a good idea. At the very least, push for more effort to be put into the upgrade process, lets get someone to build more than just a wizard, build a tool that does the upgrade and includes a ton of additional libraries to help with transitioning older code. That would be a lot of work, but the end result is still better than just doing incremental development on VB6.

By the way, this is as good of time as any to point out that I do believe that there is something missing in the .NET world right now. We need an Access-like tool for .NET... not what VB6 was, which was really much too complicated for the level of developer I'm thinking of... but something that is a drag-and-drop database form focused application creation tool. Like Access, Filemaker Pro, Hypercard, etc... but producing .NET code behind the scenes so that you can extend simple applications created using this tool with code produced out of VB.NET/C#. I think I'll call it Access.NET :)

 
 
 
免责声明:本文为网络用户发布,其观点仅代表作者个人观点,与本站无关,本站仅提供信息存储服务。文中陈述内容未经本站证实,其真实性、完整性、及时性本站不作任何保证或承诺,请读者仅作参考,并请自行核实相关内容。
2023年上半年GDP全球前十五强
 百态   2023-10-24
美众议院议长启动对拜登的弹劾调查
 百态   2023-09-13
上海、济南、武汉等多地出现不明坠落物
 探索   2023-09-06
印度或要将国名改为“巴拉特”
 百态   2023-09-06
男子为女友送行,买票不登机被捕
 百态   2023-08-20
手机地震预警功能怎么开?
 干货   2023-08-06
女子4年卖2套房花700多万做美容:不但没变美脸,面部还出现变形
 百态   2023-08-04
住户一楼被水淹 还冲来8头猪
 百态   2023-07-31
女子体内爬出大量瓜子状活虫
 百态   2023-07-25
地球连续35年收到神秘规律性信号,网友:不要回答!
 探索   2023-07-21
全球镓价格本周大涨27%
 探索   2023-07-09
钱都流向了那些不缺钱的人,苦都留给了能吃苦的人
 探索   2023-07-02
倩女手游刀客魅者强控制(强混乱强眩晕强睡眠)和对应控制抗性的关系
 百态   2020-08-20
美国5月9日最新疫情:美国确诊人数突破131万
 百态   2020-05-09
荷兰政府宣布将集体辞职
 干货   2020-04-30
倩女幽魂手游师徒任务情义春秋猜成语答案逍遥观:鹏程万里
 干货   2019-11-12
倩女幽魂手游师徒任务情义春秋猜成语答案神机营:射石饮羽
 干货   2019-11-12
倩女幽魂手游师徒任务情义春秋猜成语答案昆仑山:拔刀相助
 干货   2019-11-12
倩女幽魂手游师徒任务情义春秋猜成语答案天工阁:鬼斧神工
 干货   2019-11-12
倩女幽魂手游师徒任务情义春秋猜成语答案丝路古道:单枪匹马
 干货   2019-11-12
倩女幽魂手游师徒任务情义春秋猜成语答案镇郊荒野:与虎谋皮
 干货   2019-11-12
倩女幽魂手游师徒任务情义春秋猜成语答案镇郊荒野:李代桃僵
 干货   2019-11-12
倩女幽魂手游师徒任务情义春秋猜成语答案镇郊荒野:指鹿为马
 干货   2019-11-12
倩女幽魂手游师徒任务情义春秋猜成语答案金陵:小鸟依人
 干货   2019-11-12
倩女幽魂手游师徒任务情义春秋猜成语答案金陵:千金买邻
 干货   2019-11-12
 
推荐阅读
 
 
 
>>返回首頁<<
 
靜靜地坐在廢墟上,四周的荒凉一望無際,忽然覺得,淒涼也很美
© 2005- 王朝網路 版權所有