Skip to content

How to call css files in asp.net

Asked Jul 19, 2012, 1:20 AM EDT1 answer
Share
LinkedInX
i created 2 css files for multi languages application in asp.net using resx files concept. my languages are English and Arabic.   how to call css files based on my selection(english or arabic).

1 Answer

Know the answer? Post it. Somebody with the same question will find it here.

  • 0
    HtmlLink css = new HtmlLink(); css.Href = "css/myCurrentLanuageStylesheet.css"; // Put your file path defined by logic here! css.Attributes["rel"] = "stylesheet"; css.Attributes["type"] = "text/css"; css.Attributes["media"] = "all"; Page.Header.Controls.Add(css);
    0