I want to check when a create a buffer on arcmap, how can I make the buffer transparent? I am using vb.net arcobjects.
Any advice will be appreciated.
Actually you can get something that is pretty close to transparency on the ISymbol interface. So let's say you have created a graphic element (a IFillShapeElement could be a polygon or a rectangle as shown below). You will then find the the ISymbol:ROP2 and by setting it equal to esriROPMaskPen, it makes for a nice semi-transparent fill.
Dim fillShapeEl As IFillShapeElement
Set fillShapeEl = rect
Dim sfs As ISimpleFillSymbol
Set sfs = New SimpleFillSymbol
Dim rgb As IRgbColor
Set rgb = New RgbColor
rgb.Red = 255
'rgb.Transparency = 50 'This doesn't behave as expected...still 100% opaque
Dim sym As ISymbol
Set sym = sfs
sym.ROP2 = esriROPMaskPen 'This is the magic line!!
sfs.Color = rgb
fillShapeEl.Symbol = sfs
gc.AddElement rect, 0
Assuming your buffer exists in a layer and is not just some polygon then you can use the interface ILayerEffects to alter the transparency. Only layers support transparency, so if you were intending to create a polygon buffer and display it as a graphic then that will not work.
Thanks for the reply. I have already create a transparent buffer (for polygon), but now I am unable to remove the colour of the boundary of the buffer.
Hi Duncan & Taig,
I have already resolved the issue, thanks a lot for the attention and help.
Retrieving data ...