版权说明:本文档由用户提供并上传,收益归属内容提供方,若内容存在侵权,请进行举报或认领
文档简介
1、VB6.0和VB.Net的对照表VB6.0VB.NETAddItem Object 名.AddItemObject 名.Items . Add ListBox1 . Items . Add ComboBox1 Items . AddAbs函数System.Math.Abs 方法API函数关系App.Path 等1. System.Reflection.Assembly.GetExecutingAssembly.Location2. Application.StartupPath3. Application.ExecutablePath4. System.AppDomain.CurrentDom
2、ain.BaseDirectoryApp.PrevInstanceProcess . GetProcessesByName (pn). GetUpperBound (0) 0As Any关键词Visual Basic .NET不提供支持。参考方法(SendMessage)AscB函数Microsoft . VisualBasic . Strings . Asc 函数Atn函数System.Math.Atan 方法AutoRedraw 属性没有相同项目。BeepMicrosoft . VisualBasic . Beep()Caption 属性Text属性CBool函数CBool函数CByte函
3、数CByte函数CDate函数CDate函数CDbl函数CDbl函数CDec函数CDec函数ChDir语句Microsoft.VisualBasic.FileSystem.ChDir函数System.IO.Directory.SetCurrentDirectory方法ChDrive 语句Microsoft.VisualBasic.FileSystem.ChDrive函数Chr$函数、ChrB函数Microsoft.VisualBasic.Strings.Chr函数CInt函数CInt函数Circle 方法System.Drawing.Graphics.DrawEllipse方法CLong函数C
4、Long函数Close语句Microsoft.VisualBasic.FileSystem.FileClose函数System.IO.StreamReader.Close方法Clipboard 对象System.Windows.Forms.Clipboard命名空间ClipControls 属性没有相同项目。Cls方法System.Drawing.Graphics.Clear方法Color QBColorvbBlack RGB()System.Drawing.Color.BlackCommandSystem.Environment.GetCommandLineArgsCombol.AddIte
5、mComboBox1 Items . AddCos函数System.Math.Cos 方法CSng函数CSng函数CStr函数CStr函数CurDir 函数System.IO.Directory.GetCurrentDirectory()方法Currency 类型Decimal 类型CurrentX 属性各种图形相关方法的x 参数。比如、 DrawRectangle(pen, x, y, width, height)CurrentY 属性各种图形相关方法的y 参数。比如、 DrawRectangle(pen, x, y, width, height)Date函数、Date语句System. D
6、ateTime . Now System.DateTime.Today.ToStringDate$函数Microsoft.VisualBasic.DateAndTime.DateStringDateAdd 函数System.DateTime.AddYears 方法 AddMonths AddDaysDateDiff 函数Microsoft.VisualBasic.DateDiff函数DateValue 函数System.DateTime.Parse 方法 CDate 函数DatePart 函数Microsoft.VisualBasic.DatePart函数Day函数System.DateTim
7、e.Day 属性Debug.PrintDebug.WriteLineDeleteSetting 语句Microsoft.VisualBasic.Interaction.DeleteSettingDoEvents 函数System.Windows.Forms.Application.DoEvents方法DrawMode 属性System.Drawing.Pen.C010r属性DrawStyle 属性System.Drawing.Pen.PenType 属性DrawWidth 属性System.Drawing.Pen.Width 属性EnvironMicrosoft.VisualBasic.Int
8、eraction.EnvironSystem.Environment.GetFolderPathExp函数System. Math. Exp 方法FillColor 属性System.Drawing.SolidBrush.C010r属性FileCopy 语句Microsoft . VisualBasic . FileSystem . FileCopy 函数System.IO.File.Copy 方法FileLen 函数System.IO.FileInfo.Length属性Microsoft.VisualBasic.FileSystem.FileLenFillStyle 属性System.Dra
9、wing.Pen.Brush 属性Get语句Microsoft.VisualBasic.FileSystem.FileGet函数GetAttrSystem. IO. File . GetAttributesGotFocus 事件Enter事件GetSetting 语句Microsoft.VisualBasic.Interaction.GetSettingFileDateTime 函数System. IO. File . GetCreationTime 方法HasDC属性没有相同项目。HDC属性没有相同项目。Height 属性Control.Size 属性Hour函数System.DateTim
10、e.Hour 属性hwnd Forml.hwndForm1. Handle 定义处也是 ByVal hWnd As IntPtrmage属性Image属性nput # 语句Microsoft.VisualBasic.FileSystem.Input函数nStr 函数System.String.IndexOfMicrosoft . VisualBasic . Strings . InStr 函数nStrB 函数Microsoft.VisualBasic.Strings.InStr函数nStrRev 函数System.String.LastIndexOf方法Microsoft.VisualBasi
11、c.Strings.InStrRev函数nt函数System.Math.Floor 方法 System.Math.Ceiling方法Microsoft . VisualBasic . Int 函数nteger 类型Long类型Dim y As Integer 改为 Dim x As ShortDim y As Long 改为 Dim y As IntegersEmpty 函数Microsoft.VisualBasic.Information.IsNothing函数sDate 函数Microsoft.VisualBasic.IsDate函数sNull 函数Microsoft.VisualBasi
12、c.Information.IsDBNull函数sObject 函数Microsoft.VisualBasic.Information.IsReference函数Join函数System.String.Join方法KeyAsciie. KeyChar 属性Kill 语句Microsoft.VisualBasic.FileSystem.Kill函数System.IO 命名空间 FileInfo.Delete方法LBound UBoundSystem.Array.GetLowerBound System.Array.GetUpperBoundLCase$函数String.ToLower 方法Mic
13、rosoft.VisualBasic.Strings.LCase函数Left属性Control.Location属性Left$、LeftB、LeftB$System.String.SubStringMicrosoft.VisualBasic.Strings.Left函数LenSystem.String.LengthMicrosoft.VisualBasic.Strings.LenLenBSystem.Text.Encoding.GetEncoding(gb2312).GetByteCount(str1)System. Text. Encoding . Unicode . GetByteCoun
14、t (123 大小大)结果 12System. Text. Encoding . Default . GetByteCount (123 大小大)结果 9Line 方法System.Drawing.Graphics.DrawLine方法Line Input # 语句Microsoft.VisualBasic.FileSystem.LineInput函数List1.AddItemListBoxl . Items . AddLoadPicture 函数System.Drawing.Image.FromFile(.test.bmp)Lock语句Microsoft.VisualBasic.FileSy
15、stem.Lock函数Log函数system.Math.Log 方法Long类型Integer 类型Dim y As Integer 改为 Dim x As ShortDim y As Long 改为 Dim y As IntegerLostFocus 事件Leave事件LTrim$函数System.String.TrimStartMicrosoft.VisualBasic.Strings.LTrim函数Mid函数System.String.SubStringMicrosoft.VisualBasic.Strings.Mid函数MidB函数Microsoft.VisualBasic.Strin
16、gs.Mid函数Minute函数System.DateTime.Minute 属性MkDir语句Microsoft.VisualBasic.FileSystem.MkDir函数System.IO.Directory.CreateDirectory方法MousePointer=11Screen.MousePointerSystem.Windows.Forms.Cursors.WaitCursor()System. Windows. Forms. Cursor . Current = Cursors . WaitCursorMod运算符Math.IEEERemainder 方法 Debug.Wri
17、teLine(Math.IEEERemainder(10, 3)结果 1System.Math.DivRem(10, 3, intResult)结果 3 (10 3)Debug.WriteLine(intResult)结果 1 (10 Mod 3)Month函数System.DateTime.Month 属性MsgBoxSystem.Windows.Forms.MessageBox.Show(Hello, world!)Microsoft . VisualBasic . MsgBoxName语句Microsoft.VisualBasic.FileSystem.Rename函数Now函数Syst
18、em. DateTime . Now Microsoft.VisualBasic.NowOpen语句Microsoft.VisualBasic.FileSystem.FileOpen函数Option Base 语句Visual Basic .NET没有提供支持。Option PrivateVisual Basic .NET没有提供支持。PaintPicture 方法System.Drawing.Graphics.DrawImage方法Point方法不存在相同的 Form和控件。使用 Bitmap 时用 System.Drawing.Bitmap.GetPixel方法Print 方法System
19、.Drawing.Graphics.DrawString方法PrintFormVisual Basic .NET没有提供支持。Print# 语句Microsoft.VisualBasic.FileSystem.Print函数Private 语句Public 语句Private PublicFriend Protected Protected FriendPset方法不存在相同的 Form和控件。使用 Bitmap 时用 System.Drawing.Bitmap.SetPixel方法Put语句Microsoft.VisualBasic.FileSystem.FilePut函数Replace 函
20、数Microsoft . VisualBasic . Strings . Replace 函数Right$ 函数、RightB 函数System.String.SubStringMicrosoft.VisualBasic.Strings.Right函数ReDim语句ReDim MyArray(5) ReDim Preserve MyArray(15)语句RmDir语句Microsoft.VisualBasic.FileSystem.RmDir函数 System.IO.Directory.Delete()方法Round函数System.Math.Round 方法RTrim$函数System.St
21、ring.TrimEndMicrosoft.VisualBasic.Strings.RTrimSaveSetting 语句Microsoft.VisualBasic.Interaction.SaveSetting函数Scale方法Visual Basic .NET没有提供支持。Screen.ActiveControlScreen.ActiveFormScreen.FontsScreen.HeightScreen.MousePointerScreen.Width其他Screen 对象System.Windows.Forms.Application.ActiveForm.ActiveControl
22、 System.Windows.Forms.Application.ActiveFormSystem.Drawing.FontFamiliesSystem.Windows.Forms.Screen.PrimaryScreen.Bounds.Height System.Drawing.Cursor.CurrentSystem.Windows.Forms.Screen.PrimaryScreen.Bounds.Width 其他Second函数System.DateTime.Second 属性SendKeys 语句System. Windows. Forms. SendKeys. Send(AC)S
23、etAttrSystem. IO. File . SetAttributesSgn函数System.Math.Sign 函数ShellMicrosoft . VisualBasic . ShellSin函数System.Math.Sin 函数Space函数Microsoft.VisualBasic.Strings.Space函数Sqr函数System.Math.Sqrt 函数StrComp 函数Microsoft . VisualBasic . Strings . StrComp 函数StrConv 函数Microsoft . VisualBasic . Strings . StrConv 函
24、数String$(256, Chr(0)buf = New String(CChar( ), 256)Microsoft . VisualBasic . Strings . StrDup 函数StrReverse 函数Microsoft.VisualBasic.Strings.StrReverse函数Tan函数System. Math. Tan 方法TextHeight 属性System.Drawing.Font.Height属性TextWidth 属性System.Drawing.Graphics.MeasureString方法Time$函数Microsoft.VisualBasic.DateAndTime.Timer属性System.DateTime.Now.TimeOfDayTimeValue
温馨提示
- 1. 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。图纸软件为CAD,CAXA,PROE,UG,SolidWorks等.压缩文件请下载最新的WinRAR软件解压。
- 2. 本站的文档不包含任何第三方提供的附件图纸等,如果需要附件,请联系上传者。文件的所有权益归上传用户所有。
- 3. 本站RAR压缩包中若带图纸,网页内容里面会有图纸预览,若没有图纸预览就没有图纸。
- 4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
- 5. 人人文库网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对用户上传分享的文档内容本身不做任何修改或编辑,并不能对任何下载内容负责。
- 6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
- 7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。
最新文档
- 2026年中学教师职称考试试题及答案
- 2026年国家知识产权战略实施策略考试及答案
- 2026年会考安徽英语试卷及答案
- 人教版(新教材)三年级下册语文第八单元第25课《慢性子裁缝和急性子顾客》(第一课时)教学课件
- 体育行业智能场馆预约管理方案
- 2026初中多元文化教育课件
- 2026初中勇敢教育第一课课件
- 智慧园区建设与运营规范指南
- 金融服务消费者保护承诺书(5篇)
- 食品卫生与安全知识普及指导书
- 2025年西藏自治区公务员行政职业能力测验真题试卷含详细解析
- 2025内蒙古维拉斯托矿业有限公司招聘6名笔试历年典型考点题库附带答案详解试卷2套
- 中考英语固定搭配专项提升练习
- 燃气站场施工技术交底
- 心理咨询进社区工作方案
- 工程项目钥匙交接记录范本
- 人教版高中生物选择性必修3第1章发酵工程基础过关检测(含解析)
- 中国工商银行2026年度校园招聘考试参考题库及答案解析
- 安全及节能驾驶培训内容课件
- 2025年乡镇社会福利院管理岗位竞聘面试技巧与题库
- 2025至2030餐饮美食广场行业市场深度研究及发展前景投资可行性分析报告
评论
0/150
提交评论