public static string GetScriptWrite(string Version, int Width, int Height, FlashAllowScriptAccess AllowScriptAccess, FlashWmode Wmode, FlashSalign Salign, FlashScale Scale, Color BgColor, string FlashVars, string Movie, string FlashId, string DivIdForContainer) { string DivId = string.IsNullOrEmpty(DivIdForContainer) ? "div" + FlashId : DivIdForContainer; Dictionary <string, string> nv = new Dictionary <string, string>(); nv.Add("menu", "false"); nv.Add("allowScriptAccess", AllowScriptAccess.ToString()); nv.Add("wmode", Wmode.ToString()); nv.Add("salign", Salign.ToString()); nv.Add("scale", Scale.ToString()); nv.Add("bgcolor", CColorConv.GetHexaByColor(BgColor)); nv.Add("flashvars", FlashVars); string Params = CScript.GetScriptKeyValueByColon(nv, true); string s = ""; if (string.IsNullOrEmpty(DivIdForContainer)) { s += "<div id=\"" + DivId + "\">" + "<a href=\"http://www.adobe.com/go/getflashplayer\">" + "<img src=\"http://www.adobe.com/images/shared/download_buttons/get_flash_player.gif\" alt=\"Get Adobe Flash player\" />" + "</a>" + "</div>\r\n"; } List <string> aStmt = new List <string>(); aStmt.Add("var flashvars = false;"); aStmt.Add("var params = { " + Params + " };"); aStmt.Add("var attributes = { id: \"" + FlashId + "\", name: \"" + FlashId + "\" };"); aStmt.Add("swfobject.embedSWF(\"" + Movie + "\", \"" + DivId + "\", \"" + Width.ToString() + "\", \"" + Height.ToString() + "\", \"" + Version + "\", \"\", flashvars, params, attributes);"); string s2 = CScript.GetScript(aStmt, true); return(s + s2); }