Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
public List<HtmlGenericControl> ControlDefinitionJavascripts(string folderPathJs)
{
genericControl = new List<HtmlGenericControl>();
try
{
HtmlGenericControl jsLinkJquery = new HtmlGenericControl("script");
jsLinkJquery.Attributes.Add("type", "text/javascript");
jsLinkJquery.Attributes.Add("src", folderPathJs + "/jquery.min.js");
genericControl.Add(jsLinkJquery);
HtmlGenericControl jsLinkBootstrap = new HtmlGenericControl("script");
jsLinkBootstrap.Attributes.Add("type", "text/javascript");
jsLinkBootstrap.Attributes.Add("src", folderPathJs + "/bootstrap.min.js");
genericControl.Add(jsLinkBootstrap);
HtmlGenericControl jsLinkCustom = new HtmlGenericControl("script");
jsLinkCustom.Attributes.Add("type", "text/javascript");
jsLinkCustom.Attributes.Add("src", folderPathJs + "/custom.js");
genericControl.Add(jsLinkCustom);
return genericControl;
}
catch (Exception ex)
{
throw ex;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.