I set the formula but it won't change on the form from vb.net.

J

Joseph Burton

The form ask me if I want to save the file, but when I opened up the page the
change didn't happen. What am I forgetting.

I'm just trying to change the foreground from code but its not working.
'Instance of Visio
Dim appVisio As Visio.Application
'Documents collection of instance
Dim docsObj As Visio.Documents

Dim shpObj As Visio.Shape
Dim cellObj As Visio.Cell
Dim sectionObj, rowFill, fillForeGround As Short
sectionObj = CInt(Visio.VisSectionIndices.visSectionObject)
rowFill = CInt(Visio.VisRowIndices.visRowFill)
fillForeGround = CInt(Visio.VisCellIndices.visFillForegnd)

appVisio = CType(CreateObject("Visio.invisibleapp"),
Visio.Application)
docsObj = appVisio.Documents
docsObj.Open("C:\Documents and
Settings\joeburton\Desktop\JoeDrawing.vsd")

pagObj = pagsObj.Item(1)

'point to shape
shpObj = pagObj.Shapes.Item("JoJoPointer")
cellObj = shpObj.CellsSRC(sectionObj, rowFill, fillForeGround)
cellObj.Formula = CStr(5)

appVisio.Quit()
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top