Click or drag to resize

DialogsExtensionsOnDialogsToPath Field

Event for SOWI Web Foundation Dialogs Extensions ToPath(Dialogs)

Namespace:  SOWIWeb.Foundation
Assembly:  SOWIWeb.Foundation (in SOWIWeb.Foundation.dll) Version: 19.1.23.1 (19.1.23.622)
Syntax
public static EventHandler<EventArgsViewEnum<Dialogs>> OnDialogsToPath

Field Value

Type: EventHandlerEventArgsViewEnumDialogs
Examples
This example puts a costum view path

Adds event handler for a custom view path setting

//* add event handler for a custom view path setting *
SOWIWeb.Foundation.DialogsExtensions.OnFormsToPath += this.DialogsToPath;
Event handler puts custom view path
/// <summary>
/// Custom Dialog default view path
/// </summary>
/// <param name="sender">null object because it's static declaration</param>
/// <param name="e">Has view name and view path</param>
private void DialogsToPath(object sender, SOWIWeb.Foundation.EventArgsViewToPathEnum<SOWIWeb.Foundation.Dialogs> e)
{
    switch (e.View)
    {
        case Forms.Import:
            e.Path = "~/Views/MyDialog/Import";
            break;
        default:
            break;
    }
}
See Also