Try our conversational search powered by Generative AI!

Problem with dynamic content settings

Vote:
 

Using CMS 7 (7.0.586.16) I can't figure out how what I'm doing wrong since the value in the PropertyString isn't persisted in the dynamic content settings.

	[DynamicContentPlugIn(DisplayName = "Test")]
	public class PriceDynamicContentPlugin : IDynamicContentView
	{
		public PriceDynamicContentPlugin()
		{
			Properties = new PropertyDataCollection { new PropertyString() };
		}
 
		public string State { getset; }
 
		public PropertyDataCollection Properties { getprivate set; }
 
		public void Render(TextWriter writer)
		{
			writer.Write(State);
		}
	}

 

#74770
Sep 06, 2013 14:12
Vote:
 

I would try to name the property to another name then State, might be that word is reserved in some way.

#74775
Sep 06, 2013 15:15
Vote:
 

The property State is from the interface IDynamicContentView

#74778
Sep 06, 2013 15:30
Vote:
 

I see, haven't worked with DC in EPi7, so just made an assumption. :/

#74782
Sep 06, 2013 15:33
This thread is locked and should be used for reference only. Please use the Episerver CMS 7 and earlier versions forum to open new discussions.
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.