资源描述:
《简明vb教程,学业水平测试必过(concise vb tutorial, academic proficiency test must go)》由会员上传分享,免费在线阅读,更多相关内容在教育资源-天天文库。
1、简明vb教程,学业水平测试必过(ConciseVBtutorial,academicproficiencytestmustgo)Herearesomebasictermsofobjectorientedprogramming.1,objectsTheVisualBasicobjectisdifferentfromthegeneralobjectorientedlanguage,itisreallyspecific,youcanseeaform,suchas:button,withouttheneedforextensiveobjectcommandtodefi
2、netheobjectcodeanddatablock.YoucanseetheautomaticgenerationofVisualformintheBasicafterthestart,thenwejustneedtogetsomecontrols(actuallyobjects)suchasatextbox,buttonaddedtotheformtocompletethepreparationoftheinterface,thisisVisualBasicthemostuniqueplace.2,eventsInVisualBasic,therespo
3、nseobjectcalledtheevent,andbetweentheobjectandtheobjectandprocedurethroughtheevent,suchasamouseclickbuttonthatwillgenerateaClickeventforthisevent,ifwewritethecorrespondingcode,theprocessofthesystemwillexecutethiscode.Whentheprocessiscompleted,thecontrolishandedbacktothesystem,waitin
4、gforthenexteventtohappen.3,attributesInVisualBasic,thedataintheobjectisstoredintheattribute,allobjectshaveattributes,suchastheTextattributeofthetextboxisthetextcontentwithinthetextbox.4,methodsInVisualBasic,objectscontainnotonlydata,butalsocodethatoperatesondata,whichiscalledamethod
5、.Well,herewegotoourtopic,howtouseVisualBasicforprogramming,hereonthemaininterfaceofVisualBasicIwillnotgiveadetaileddescription.Ifyoulookatabookoroperateit,youwillunderstanditgradually.ThefollowingforeachobjectintheVisualBasic,thatis,theform,controltoexplain,otherrelatedbasicknowledg
6、ewillnotbeexplainedindetail.Chapter1,formsInVisualBasic,themostimportantobjectistheform,andallotherobjectscanonlyexistontheform.Solet'stalkaboutthemainattributes,events,methodsusedbytheformobject.First,attribute1,Name,whichisthemostbasicattribute,allcontrolshavethisproperty,mainlyus
7、edtoidentifyanobject.2,Caption,istouseittosettheformofthetitle,ingeneral,toopenaprogram,isthefirsttoseetheformofthetitle,sothetitleisoftentheprogramfeaturesasimplesolutionorprocedurename.3,Icon,whichistheiconthatappearsontheleftofthetitle.IfyouhatetheformiconthatrepresentsVB,chooseo
8、netoreplaceit.Tip:s