I'm trying to create a template that sends a welcome to <business> email to clients, and I want it to contain more text that the recovery url, so I extended the custom section in Website settings with a subject and a content field.
Now I need to grab these fields into my email template, which I have located in the \Files\Templates\ExtranetExtended (not Rapido. If I created the same path in Rapido, it doesn't show up).
I copied the code from an earlier created template (I want the business logo and colours in header and footer). I had to change the include paths. But now I get an error, nullpointerexception
This is my item type settings
I have tried two different ways of retrieving the values, but they both fail.
string emailSubject = Pageview.AreaSettings.GetItem("Custom").GetItem("CustomSettings").GetString("EmailNewCustomerSubject");
string emailSubject = Pageview.AreaSettings.GetItem("CustomSettings").GetString("EmailNewCustomerSubject");
I also tried
string emailSubject = Model.Item.GetItem("Custom").GetItem("CustomSettings").GetString("EmailNewCustomerSubject");
Now, how do I proceed?