资源描述:
《复件 vfp面向对象程序设计》由会员上传分享,免费在线阅读,更多相关内容在教育资源-天天文库。
1、财管VFP33-34学时(面向对象程序设计2)2009-12-18对象是构成程序的基本单位和运行实体。在VFP中,控件可分为控件和容器两种。属性是对象的特征。有两种设置方法。事件是对象可以识别的动作。事件触发的方式三种:用户行为(如单击);系统(如时钟);由代码引发(如调用方法程序CLS)一旦触发事件,就按照预先规定的方法去执行某个过程。用户不能创建新的事件。方法是系统内定的通用过程。方法程序代码由VFP定义,用户不可见。如CLS。用户可以为对象扩充新的方法。总结:一个对象有多个属性,一个对象可以有多个事件,每个
2、事件都要有一个动作(方法程序)。而一个应用程序会包含多个对象。例1、Circle方法与系统事件的时间顺序(Activate事件在load事件之后)方法类事件代码窗口的命令,即可以直接在该事件上书写,也可以由引起该方法的事件触发。form1-Activate:this.circle(50,100,50)&&画圆(半径50,横X轴圆心坐标100,Y轴50)&&此时引发form1-circle方法form1-load:thisform.cls&&程序运行后,可见到圆。如果将两个事件的程序调换,则看不到圆。例2、控件的载
3、入时间在load事件之后,在Activate和int事件之前①form1-clickthisform.text1.value="中国人民"&&正常显现②form1-loadthisform.text1.value="中国"&&“不能识别的成员text1”③form1-Activatethisform.text1.value="中国"&&正常显现④form1-inturbanarea2.5.2YibincityinYibincity,accordingtoresourceandenvironmentcharacte
4、risticsUrbanpopulationandurbanspatialdistribution,spatialdistributionofindustries,majorinfrastructureCorridorlayout,combinedwiththefuturedevelopmenttrendofsyntheticjudgments,planning,urbanspatialstructureofurbansystemcanbesummarizedas:"apolealongthetwoaxes"."
5、A"referstothemetropolitanareaalongtheYangtzeRiver,isthecoreareaofthedevelopmentofthecity.PlanstobuildfortheYangtzeRivereconomicbeltonthepillar,advancingalongthe...GuangheRiver,Yiliang,prestigeoftheexternalcohesionofzhaotong,Yunnan,internalconnectingYibincityt
6、otheNorth.TheSichuan-Yunnan-GuizhouborderareaofYibin,inthecityofzhaotong,liupanshuithree,zhaotongcity,themostpopulousandmostextensiveregions,themosteconomicallybackward,totheNorthinWumengmountainareaofyanjin,shuifu,suijiangcountiesradiationpowerisrelativelywe
7、ak.Yibincityandinfrastructureinsuchareasshouldbestrengthenedanddocking,extendingsouthwardtopublicservices,promotethedevelopmentofmineralresourcesinNortheastYunnan,expandoureconomichinterland,drivingsynchronousliftinginSichuan-Yunnan-Guizhouborderarea.Thisurba
8、naxiswithmineralresourceadvantages,focusonthedevelopmentofadvancedtechnology,comprehensiveutilizationofresourcesofhigherenergy,newbuildingmaterials,chemicalindustry,developingnewenergyand