Visio Guy

Visio Discussions => Programming & Code => Topic started by: billman on October 13, 2020, 10:52:45 PM

Title: Divided Box Stencil Shape: accessing shape text
Post by: billman on October 13, 2020, 10:52:45 PM
The Divided Box stencil shape is great, but I'm having trouble with it in VBA.  If it was a standard box shape, I can get the text content of the box with shp.Text - but the Divided Box shape just produces a "?" for this property.  I've been playing around with hTxtTop and hTxtBottom and can't figure out how to use these properly - or even if they're the right thing to use.  Can anyone tell me how to get the text in the top and the text in the bottom of the box?

Thanks - Bill
Title: Re: Divided Box Stencil Shape: accessing shape text
Post by: billman on October 13, 2020, 11:04:21 PM
Isn't it always the case that I figure out the answer right after posting the question?

        intTemp = shpEntity.Shapes.Item(1).Text
        intTemp2 = shpEntity.Shapes.Item(2).Text