Simply trying to read a cell

D

dave

I'm trying to test the value in a custom property What am I doing wrong.

If vsoShape.CellU("Prop.ModuleType") = """9IDM""" Then "DoThatThing"

Dave
 
C

Chris Roth [ Visio MVP ]

You've stopped at the cell object and not at what the cell contains:

CellU("...").Formula = "..."

or

CellU("...").ResultString(Visio.VisResultCodes.VisNoCast) = "..."

FYI, there's also Cell.ResultIU which returns numeric results in inches. And
Cell.Result( unitcode ) which gets you a number of a specific unit.

--

Hope this helps,

Chris Roth
Visio MVP
 
J

junethesecond

If vsoShape.CellsU("Prop.ModuleType").Formula = """9IDM""" Then
"DoThatThing" wpuld be hopeful.
 
C

Chris Roth [ Visio MVP ]

Also, I *think* if you use ResultStr, you can get rid of one set of "" "" on
either side.

--

Hope this helps,

Chris Roth
Visio MVP
 
D

dave

Thanks Junethesecond,
I missed the s in Cells and the .formula Now it works prefectly
Dave
 

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