open a new window with button inside an ajax update panel
Get link
Facebook
X
Pinterest
Email
Other Apps
-
ScriptManager.RegisterClientScriptBlock(UpdatePanel1, UpdatePanel1.GetType(), "Any Name you Like", "Window.open('default.aspx','','height=100,width=100');", true);
Name spaces to include: using System; using System.Text; using System.Threading; ---------------------------------------------- Progress bar class: class progressBar { /// <summary> /// An ASCII progress bar /// </summary> public class ProgressBar : IDisposable, IProgress<double> { private const int blockCount = 40; private readonly TimeSpan animationInterval = TimeSpan.FromSeconds(1.0 / 8); private const string animation = @"▀▀▀▀▄▄▄▄";//@"▀▀▀▀▄▄▄▄" @"|/-\"; ...
Just call this method at the very end of your C# application to delete application’s executable file. /// <summary> /// This method deletes the exe that calls it. /// /// This method must be called right at the end of the application. /// </summary> private static void SelfDestroy() { var startInfo = new ProcessStartInfo(); startInfo.FileName = "cmd.exe" ; startInfo.RedirectStandardInput = true ; startInfo.UseShellExecute = false ; var process = new Process(); process.StartInfo = startInfo; process.Start(); // The delay is just making sure the exe to delete is done // running. var delayPings = 2; var exeName = AppDomain.CurrentDomain.Friend...
Asp.net set session timeout in web.config, Global.asax and IIS Introduction: Here I will explain how to set session timeout in web.config,IIS and in application using asp.net manually. Description: By default our websites session timeout is 20 mins after that session will gets expire suppose if we want to set our custom timeout in our applications we can set it in different ways (web.config, global.asax and in IIS) Check below methods to set session timeout in web.config, global.asax and in iis In Web.config file we can set session timeout like as shown below < configuration > < system.web > < sessionState mode = " InProc " timeout = " 60 " > </ sessionState > </ system.web > </ configuration > In Global.asax file we can set session timeout in Session_Start event like this void Session_Start( object sender, ...
Comments
Post a Comment