ObjectARX
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

COM Properties: Displaying An Array

3 REPLIES 3
Reply
Message 1 of 4
Kyudos
221 Views, 3 Replies

COM Properties: Displaying An Array

My custom object has some arrays of structures I'd like to put in the property panel in a way similar to the Vertex spinner for polylines. But it seems (if I understand correctly) IOPMPropertyExpander is only used for point properties?

 

I'm assuming I could add my array index as a property, track it, and use it to display the correct 'sub values' - but I wouldn't get the spinner. Is that how I should do this?

3 REPLIES 3
Message 2 of 4
Kyudos
in reply to: Kyudos

Further investigation shows that using IOPMPropertyExpander works fine for the double values in my structure, but not the strings.

 

Is there a cunning trick to make it work? I realise I can fake it by just using that interface to introduce the spinner with the appropriate sizing. I can then use the dwCookie to calculate / track the array index, which I could then use in a set of 'standard' properties. Would be nice if I didn't have to though...

Message 3 of 4
Kyudos
in reply to: Kyudos

So I'm  using IOPMPropertyExpander for the numerical values in my array and tracking the 'active' array index. I was planning to use that index to update the string values from the array that I'm displaying under a different DISPID. However, I can't find a way to force an update to my string field in the grid (at best) or even update the whole property panel (not ideal, but would work).

 

Does anyone know how to do this?

Message 4 of 4
Kyudos
in reply to: Kyudos

I can sort of get this to work by calling a propPut from GetElementValue, but this results in an infinite update loop so I have to use a bit of debugger jiggery-pokery to see it.

 

Anyone got any other ideas?

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk Design & Make Report

”Boost