dsea
路人甲
路人甲
  • 注册日期2003-09-22
  • 发帖数60
  • QQ
  • 铜币161枚
  • 威望0点
  • 贡献值0点
  • 银元0个
阅读:1373回复:1

请帮看看下面画专题图的程序有什么错误?

楼主#
更多 发布于:2004-09-13 11:24
<P ><FONT face="Times New Roman" size=3>Dim pGraphicsContainer As IGraphicsContainer</FONT></P>
<P ><FONT size=3><FONT face="Times New Roman">  Dim pActiveView As IActiveView</FONT></FONT></P>
<P ><FONT size=3><FONT face="Times New Roman">  Dim pRectangle As IRectangleElement</FONT></FONT></P>
<P ><FONT size=3><FONT face="Times New Roman">  Dim pFRect As IFillShapeElement</FONT></FONT></P>
<P ><FONT face="Times New Roman" size=3>  </FONT></P>
<P ><FONT size=3><FONT face="Times New Roman">  Set pRectangle = New RectangleElement</FONT></FONT></P>
<P ><FONT size=3><FONT face="Times New Roman">  Set pFRect = pRectangle</FONT></FONT></P>
<P ><FONT size=3><FONT face="Times New Roman">  Dim pFillSym As ISimpleFillSymbol</FONT></FONT></P>
<P ><FONT size=3><FONT face="Times New Roman">  Dim pLineSym As ILineSymbol</FONT></FONT></P>
<P ><FONT face="Times New Roman" size=3>  </FONT></P>
<P ><FONT size=3><FONT face="Times New Roman">  Set pFillSym = New SimpleFillSymbol</FONT></FONT></P>
<P ><FONT size=3><FONT face="Times New Roman">  'pFillSym.Style = esriSFSSolid</FONT></FONT></P>
<P ><FONT size=3><FONT face="Times New Roman">  Dim pColor As IColor</FONT></FONT></P>
<P ><FONT size=3><FONT face="Times New Roman">  Set pColor = New RgbColor</FONT></FONT></P>
<P ><FONT size=3><FONT face="Times New Roman">  pColor.RGB = vbBlue</FONT></FONT></P>
<P ><FONT size=3><FONT face="Times New Roman">  pFillSym.Color = pColor</FONT></FONT></P>
<P ><FONT size=3><FONT face="Times New Roman">  Set pLineSym = pFillSym.Outline</FONT></FONT></P>
<P ><FONT size=3><FONT face="Times New Roman">  pColor.RGB = vbRed</FONT></FONT></P>
<P ><FONT size=3><FONT face="Times New Roman">  pLineSym.Color = pColor</FONT></FONT></P>
<P ><FONT size=3><FONT face="Times New Roman">  pLineSym.Width = 1.5</FONT></FONT></P>
<P ><FONT size=3><FONT face="Times New Roman">  pFillSym.Outline = pLineSym</FONT></FONT></P>
<P ><FONT size=3><FONT face="Times New Roman">  'pElement.Symbol = pFillSym</FONT></FONT></P>
<P ><FONT size=3><FONT face="Times New Roman">  pFRect.Symbol = pFillSym</FONT></FONT></P>
<P ><FONT size=3><FONT face="Times New Roman">  'pElement.Symbol = pFillSym</FONT></FONT></P>
<P ><FONT face="Times New Roman" size=3>'  Dim pevlope As IEnvelope</FONT></P>
<P ><FONT face="Times New Roman" size=3>'  Set pevlope = pFeature.Shape.Envelope</FONT></P>
<P ><FONT size=3><FONT face="Times New Roman">  'pElement.Geometry = pevlope</FONT></FONT></P>
<P ><FONT face="Times New Roman" size=3>  </FONT></P>
<P ><FONT face="Times New Roman" size=3>  </FONT></P>
<P ><FONT size=3><FONT face="Times New Roman">  pGraphicsContainer.AddElement pRectangle, 0  每次执行到这一步的时候会提示出错,错误信息是“object variable or with block variable is not set"我觉得我前面设置了的呀,请大家帮忙看看,谢谢</FONT></FONT></P>
<P ><p><FONT face="Times New Roman" size=3> </FONT></p></P>
<P ><FONT size=3><FONT face="Times New Roman">  pActiveView.PartialRefresh esriViewGraphics, Nothing, Nothing</FONT></FONT></P>
喜欢0 评分0
gis
gis
管理员
管理员
  • 注册日期2003-07-16
  • 发帖数15951
  • QQ
  • 铜币25345枚
  • 威望15368点
  • 贡献值0点
  • 银元0个
  • GIS帝国居民
  • 帝国沙发管家
  • GIS帝国明星
  • GIS帝国铁杆
1楼#
发布于:2004-09-13 14:07
<a href="http://www.gisempire.com/bbs/dispbbs.asp?boardid=62;id=29338" target="_blank" >http://www.gisempire.com/bbs/dispbbs.asp?boardid=62;id=29338</A>
GIS麦田守望者,期待与您交流。
举报 回复(0) 喜欢(0)     评分
游客

返回顶部