Professional UI Solutions
Site Map   /  Register
 
 

Forum

Please Log In to post a new message or reply to an existing one. If you are not registered, please register.

NOTE: Some forums may be read-only if you are not currently subscribed to our technical support services.

Forums » Prof-UIS General Discussion » How to refresh propertyGrid if a item value is modified from outside....... Collapse All
Subject Author Date
Nitesh Singh Aug 22, 2006 - 5:00 AM

Hi.....

I am asking the question through the example given in the article "Prof-UIS Property Grid" http://www.prof-uis.com/ArticleRead.aspx?AID=393

Here the color of text display is changed by changing the corresponding value in the property grid. Now.... my question is.. Suppose the color of text "My Text" is changed from somewhere else (let say.. if we write click on the text then if we can change the color of the given text... ) now the text color is changed.. so the VALUE in PropertyGrid should also be changed.. (just the reverse which is currectly supported in the given example...) .. So.. what should be done to support that...

do I have to call the Dialog with propertygrid.. and populate the propertyComboBoxBar again.... (if this is the only way.. then everytime I change my object then I have to call the perticular dialog and populate the combobox... and the object is not a member of the given dialogbox and big also.. not just CMyStatic class which is member of thet dialog... )

.... or how to reflect the values in propertyGrid.. if an object’s property is changed from outside..If you understood my point..please help...

thanks alot.... :)

Nitesh Singh Aug 23, 2006 - 10:13 PM

thank you.. Actually it was happening due to inter project function calls.......

Nitesh Singh Aug 22, 2006 - 8:00 AM

thanks for the suggestion..

but I have a query.. that.. I am attaching propertyStore of the object in ComboxBar,,....................

so will this work in my case.. thank you..

Technical Support Aug 22, 2006 - 6:54 AM

You can keep the text color value in a CExtGridCellColor object stored as the active property value inside the CExtPropertyValue object with the TextColor name. In this case the single color value will be changed both by the property grid code and by some external code. When your external code changes some property value(s) it should invoke the CExtPropertyGridCtrl::PropertyStoreSynchronize() method to update the content displayed in the property grid control.

Nitesh Singh Aug 23, 2006 - 4:35 AM

Sir.................

I have a variable CExtPropertyGridCtrl m_PGP; as member of my dialog..
Now when I am changing the object property value from outside.. and calling Dlg.m_PGP.PropertyStoreSynchronize() then it is giving an assertion somewhere in wincore.cpp....

if works fine with the sample project with CMyStatic class... But is not working in my application where object is not a member variable of the proprerty grid dialog.... what sud be done..
thanks...

Technical Support Aug 23, 2006 - 10:16 AM

We can review your project if you send it to us at support@prof-uis.com.