<%@ Page language="C#" explicit="true" %> RAWeb - Remote Applications

RemoteApps


<% string appname = ""; string basefilename = ""; string pngname = ""; string pngpath = ""; string Whichfolder = HttpContext.Current.Server.MapPath("rdp\\") + "/"; string[] allfiles = System.IO.Directory.GetFiles(Whichfolder); foreach(string eachfile in allfiles) { string extfile = eachfile.Substring(eachfile.Length - 4, 4); if (extfile.ToLower() == ".rdp") { if (!(GetRDPvalue(eachfile,"full address:s:") == "")) { appname = GetRDPvalue(eachfile, "remoteapplicationname:s:"); basefilename = eachfile.Substring(Whichfolder.Length, eachfile.Length - Whichfolder.Length - 4); if (appname == "") { appname = basefilename; } pngname = basefilename + ".png"; if (System.IO.File.Exists(HttpContext.Current.Server.MapPath("png\\" + pngname))) { pngpath = "png/" + pngname; } else { pngpath = "rdpicon.png"; } HttpContext.Current.Response.Write("
"); HttpContext.Current.Response.Write("
" + appname + "
"); HttpContext.Current.Response.Write("
"); } } } %>