tags:

views:

320

answers:

3

I have a module that sends an email to a specified email address but I want to default the email recipient to the portal administrator. How can I retrieve this information?

+1  A: 
' get the current portal
Dim portSettings As PortalSettings = PortalController.GetCurrentPortalSettings

' get email address
Dim email as string = portSettings.Email
Douglas Anderson
+3  A: 

If you are in the context of a control inheriting from PortalModuleBase, PortalSettings is available as a property, so it would just look like

PortalSettings.Email
bdukes
A: 

This was very helpful. Thanks

DClaytonGM