且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

以编程方式向 Visio 添加菜单操作

更新时间:2023-10-02 11:38:46

我最终是这样做的,而且效果很好.

I ended up doing it like this and it works just fine.

Dim formula As String
formula = "=CALLTHIS([MODULE],,[ARG1],[ARG2])"
formula = Replace(formula, "[MODULE]", Chr(34) & "ThisDocument.myFunction" & Chr(34))
formula = Replace(formula, "[ARG1]", "Prop.IPAddress")
formula = Replace(formula, "[ARG2]", "Prop.Username")

'After the formula has been created, apply it to the row
shape.CellsSRC(visSectionAction, rowBeingEdited, visActionAction).formula = formula