I'm having some difficulties in using the Castle Windsor fluent
interface and some properties that I have configured in a web.config
file.
For example, I've got the following property in a web.config file:
<castle>
<properties>
<EmailNotificationMessageFormatter_TemplatePath>C:
\Notifications\Templates</
EmailNotificationMessageFormatter_TemplatePath>
</properties>
</castle>
This is the part of the fluent interface configuration that tries to
set the parameter:
Component.For<INotificationMessageFormatter>()
.ImplementedBy<EmailNotificationMessageFormatter>
()
.Parameters(
Parameter.ForKey("templatePath").Eq("#
{EmailNotificationMessageFormatter_TemplatePath}")
)
I initialize the container this way:
_container = new WindsorContainer(new XmlInterpreter());
_container.Register(
Component.For<INotificationMessageFormatter>()
.ImplementedBy<EmailNotificationMessageFormatter>
()
.Parameters(
Parameter.ForKey("templatePath").Eq("#
{EmailNotificationMessageFormatter_TemplatePath}")
) )
Is this supposed to work or am I doing something wrong? Thanks for the
help.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Castle Project Users" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/castle-project-users?hl=en
-~----------~----~----~----~------~----~------~--~---