S
Shahzad Godil
My requirement is that I want to provide Custom Callout for each shape.
That custom callout will show custom properties for attached parent object.
Here is my code working pefectly for adding Custom Callout 1 automatically
with new shape. But it is opening dialog box also.
Open attached file and try to drop one "Process" from stencil. Here is the
code working right now
Here is the changes which I want in it.
1. This dialog box should not be open automatically.
2. All custom property should automatically checked in Callout dialog box by
default. Means default behaviour will be that a callout object will also
create with orignal shape. And it will show all properties without asking
to user.
3. I tried to set
I also tried to set properties "User.ccReportOn", User.ccParentName etc at
runtime using code but it also didn't worked.
Private Sub Document_ShapeAdded(ByVal Shape As IVShape)
If Shape.Master = "Process" Then
Dim objCallout As Shape
Set objCallout = Module1.DropMasterOnPage(Me.Pages(1), "Custom
callout 1", "CALOUT_U.VSS", Shape.Cells("PinX"), Shape.Cells("PinY") -
Shape.Cells("Height"), visInches)
Dim vsoCell1 As Visio.Cell
Dim vsoCell2 As Visio.Cell
Set vsoCell1 = objCallout.CellsSRC(visSectionControls, 0, visCtlX)
Set vsoCell2 = Shape.CellsSRC(7, 1, 0)
vsoCell1.GlueTo vsoCell2
End If
End Sub
That custom callout will show custom properties for attached parent object.
Here is my code working pefectly for adding Custom Callout 1 automatically
with new shape. But it is opening dialog box also.
Open attached file and try to drop one "Process" from stencil. Here is the
code working right now
Here is the changes which I want in it.
1. This dialog box should not be open automatically.
2. All custom property should automatically checked in Callout dialog box by
default. Means default behaviour will be that a callout object will also
create with orignal shape. And it will show all properties without asking
to user.
3. I tried to set
I also tried to set properties "User.ccReportOn", User.ccParentName etc at
runtime using code but it also didn't worked.
Private Sub Document_ShapeAdded(ByVal Shape As IVShape)
If Shape.Master = "Process" Then
Dim objCallout As Shape
Set objCallout = Module1.DropMasterOnPage(Me.Pages(1), "Custom
callout 1", "CALOUT_U.VSS", Shape.Cells("PinX"), Shape.Cells("PinY") -
Shape.Cells("Height"), visInches)
Dim vsoCell1 As Visio.Cell
Dim vsoCell2 As Visio.Cell
Set vsoCell1 = objCallout.CellsSRC(visSectionControls, 0, visCtlX)
Set vsoCell2 = Shape.CellsSRC(7, 1, 0)
vsoCell1.GlueTo vsoCell2
End If
End Sub