rbulph Posted March 25, 2013 Posted March 25, 2013 Is there any way that I can display a property in the PropertyGrid Control but not expose it when I pass the object to a dll? Quote
Leaders snarfblam Posted March 25, 2013 Leaders Posted March 25, 2013 You can have a property appear on the property grid that is not actually part of the class by using a custom TypeDescriptor (check out some tutorials on customizing the property grid), but what is the actual problem you're trying to solve here? There's likely a better solution. Quote [sIGPIC]e[/sIGPIC]
rbulph Posted April 3, 2013 Author Posted April 3, 2013 Hi, sorry for the delay in replying. What I've got is like a piping diagram. Each pipe is an object which I draw on the screen and each of these pipes contains a business object with a number of properties. I pass these business objects to dlls. The contents of each pipe can be sourced from a number of preceding pipes. The user can select that a pipe is used as a source for a secondary one. He has a choice between having whatever it contains passing through the secondary pipe or just a selected portion of what it contains passing through. At propertygrid level I want the source pipe to be shown as a line item. At dll level I want the actual contents that are passed through to be accessible. So I was thinking of having a function for the benefit of the dlls which returns the pipe contents and a property for my benefit which holds details of the relevant pipes which is visible to the propertygrid but not through dlls. Hope that makes it a bit clearer. What do you think? Quote
Leaders snarfblam Posted April 4, 2013 Leaders Posted April 4, 2013 At propertygrid level I want the source pipe to be shown as a line item. I'm not sure exactly how you want it represented in the property grid, but a tutorial on customizing the property grid (like this) should have all the info you need. It's not simple, but it's doable. Quote [sIGPIC]e[/sIGPIC]
rbulph Posted April 9, 2013 Author Posted April 9, 2013 I'm not sure exactly how you want it represented in the property grid, but a tutorial on customizing the property grid (like this) should have all the info you need. It's not simple, but it's doable. Indeed, I'm not exactly sure how I want to represent this in the grid either, but that link looks helpful, thanks. Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.