ASP.NET(C#)·µ»ØÉÏÒ»Ò³(ºóÍË)´úÂë
protected void Page_Load(object sender, EventArgs e)
{
if (!IsPostBack)
{
ViewState["BackUrl"] = Request.UrlReferrer.ToString();
}
}
/// <summary>
/// ·µ»Ø°´Å¥µã»÷ʼþ
/// </summary>
protected void Button1_Click(object sender, EventArgs e)
{
Response.Redirect(ViewState["BackUrl"].ToString());
}
ÁíÒ»ÖÖ·½·¨
ÔÚC# Web³ÌÐòÖУ¬ÈçÎªÒ³Ãæ°´Å¥Ð´·µ»ØÉÏÒ»Ò³´úÂë
this.RegisterClientScriptBlock("E", "<script language=javascript>history.go(-2);</script>");
ÆäÖУ¬history.go(-2)£¬ÒªÐ´Îª-2£¬ÒòÔÚ°´Å¥Ê¼þ´¥·¢Ç°£¬ÒÑË¢ÐÂÒ»´ÎÒ³Ãæ£¬ËùÒÔÓ¦ÊÇ-2¡£
Response.Write("<script language=javascript>history.go(-2);</script>");
´Ë´¦Ò²ÒªÐ´Îª“-2”¡£¸úÖ±½Óд½Å±¾µÄÓÐËù²»Í¬¡£
Ïà¹ØÎĵµ£º
public struct RECT
{
public int left;
public int Top;
public int Right;
public int Bottom;
}
public static bool CenterMouseOn(int hwnd)
{
......
Ò»¡¢²åͼµÄÀࣨº¬2·½·¨£©
1using System;
2using System.Collections.Generic;
3using System.Text;
4//using Excel = Microsoft.Office.Interop.Excel;
5using Excel;
6using System.Windows.Forms;
7
8
9namespace ExcelReport
10{
11 class InsertPicToExcel
12 {
13 / ......
asp.net(C#)×Ö·û´®¼ÓÃÜ
2010-03-12 09:59
using System;
using System.Collections.Generic;
using System.Text;
using System.Security.Cryptography;//CryptographyÃÜÂëÊõ
namespace DAL
{
......
ASP.NET ³É¹¦µÄÆäÖÐÒ»¸öÔÒòÔÚÓÚËü½µµÍÁË Web ¿ª·¢ÈËÔ±µÄÃż÷¡£¼´±ãÄú²»ÊǼÆËã»ú¿ÆÑ§²©Ê¿Ò²¿ÉÒÔ±àд ASP.NET ´úÂë¡£ÎÒÔÚ¹¤×÷ÖÐÓöµ½µÄÐí¶à ASP.NET ¿ª·¢ÈËÔ±¶¼ÊÇ×Ôѧ³É²ÄµÄ£¬ËûÃÇÔÚ±àд C# »ò Visual Basic® ֮ǰ¶¼ÔÚ±àд Microsoft® Excel® µç×Ó±í¸ñ¡£ÏÖÔÚ£¬ËûÃÇÔÚ±àд Web Ó¦ÓóÌÐò£¬×ܵÄÀ´Ëµ£¬ËûÃÇËù×öµÄ¹¤ ......
ÔÚûÓÐ<asp:UpdatePanel ID="up" runat="server"> <ContentTemplate>ÎÞˢл·¾³ÖУº
Response.Write("<script>alert('¹§Ï²Äú£¬Òѳɹ¦¼ÓÈëµ½ÄúµÄÈ˲ſ⣡');</script>");
ÔÚÓÐ<asp:UpdatePanel ID="up" runat="server"> <ContentTemplate>ÎÞˢл·¾³Ö ......