Ò׽ؽØͼÈí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

ÏñASPÒ»ÑùÇáËÉʵÏÖ·ÖÒ³ÏÔʾÊý¾ÝC#

 
´úÂëÈçÏ£º
<%@ Page Language="C#" Debug="true" %>
<%@Import Namespace="System.Data"%>
<%@Import Namespace="System.Data.SqlClient"%>
<Script Language="C#" runat="server">
int Record_Per_Page;//¶¨ÒåÿҳÏÔʾ¼Ç¼Êý
int nPageCount;//¶¨Òå×ÜÒ³Êý
int nRecCount;//¶¨Òå×ܼǼÊý
int nPage;//¶¨Ò嵱ǰҳ
void Page_Load(Object src,EventArgs e){
//È¡µÃµ±Ç°Ò³ÊýÖµ£¬²¢ÅжÏ
if(Request["pagesize"]==null)
Record_Per_Page=9;
else
Record_Per_Page=Convert.ToInt32(Request["pagesize"]);
//Á¬½ÓÊý¾Ý¿â
SqlConnection conn;
conn =new SqlConnection(ConfigurationSettings.AppSettings["strconn"]);
conn.Open();
//Ö´ÐÐSQLÓï¾ä
string ConnStr="select id,name,demo,pic from download where classid=23 or classid=24 order by time desc";
SqlDataAdapter odAdapt = new SqlDataAdapter(ConnStr,conn);
DataSet DS = new DataSet();
odAdapt.Fill(DS);
DataTable DT = DS.Tables[0];
//»ñµÃ×ܼǼÊý
nRecCount = DT.Rows.Count;
//ÅжÏÊÇ·ñ´æÔÚÊý¾Ý¼Ç¼
if(nRecCount > 0){
//È·¶¨Êý¾Ý¼Ç¼ҪÏÔʾµÄÒ³ÃæÊý
  nPageCount=nRecCount/Record_Per_Page;
if(nRecCount % Record_Per_Page > 0)
 nPageCount ++;
if(nPage < 1)
    nPage = 1;
if(nPage > nPageCount)
    nPage = nPageCount;
//½«Ò³ÊýÏÔʾµ½ÆÁÄ»ÉÏ£¬²¢×÷Á´½Ó
for(i=1;i<=nPageCount;i++){
   html=html+"<a href='mblist.aspx?page="+i+"&id="+classid+"&classname="+Request.Params["classname"]+"pagesize="+Record_Per_Page+"'>";
   if(i==nPage)
   html=html+"<b>"+i+"</b>";
   else
   html=html+i;
   html=html+"</a> ";
  }
  pagelist.InnerHtml=html;
  html="";
//È·Èϵ±Ç°Ò³ÃæµÄ¿ªÊ¼¼Ç¼ºÍÖÕÖ¹¼Ç¼
  int nStart = Record_Per_Page * (nPage - 1);
  int nEnd = nStart + Record_Per_Page - 1;
if(nEnd > nRecCount - 1)
    nEnd = nRecCount - 1;
//ÔÚÆÁÄ»ÖÐÊä³ö¼Ç¼
  html="<table border='0' cellpadding='0' cellspacing='0' style='border-collaps


Ïà¹ØÎĵµ£º

Ò»¸öC# xml ÐòÁл¯´íÎó

Ò»¸öC# xml ÐòÁл¯´íÎó
 
Ê·¢ÏÖ³¡£º
xmlÐòÁл¯µÄÊý¾ÝÖд洢µÄ½ÚµãÊý¾ÝÊÇ
   <Module>536870912</Module>  £¨xmlÎļþÖУ©
¶ÔÓ¦µÄÀàÊôÐÔÊÇ
    public short Module { get; set; }  £¨C#ÀàÖУ©
 
ÐòÁл¯µÄ´úÂ룺
public static FMDSTimeSeriesDefinitio ......

¡¾C#+ASP.NET¡¿ASP.NET¿çÒ³Ãæ´«Öµ¼¼ÇÉ×ܽá(ת)

¡ï1.  Ê¹ÓÃQueryString±äÁ¿
¡¡¡¡¡¡QueryStringÊÇÒ»Öַdz£¼òµ¥µÄ´«Öµ·½Ê½£¬Ëû¿ÉÒÔ½«´«Ë͵ÄÖµÏÔʾÔÚä¯ÀÀÆ÷µÄµØÖ·À¸ÖС£Èç¹ûÊÇ´«µÝÒ»¸ö»ò¶à¸ö°²È«ÐÔÒªÇ󲻸߻òÊǽṹ¼òµ¥µÄÊýֵʱ£¬¿ÉÒÔʹÓÃÕâ¸ö·½·¨¡£µ«ÊǶÔÓÚ´«µÝÊý×é»ò¶ÔÏóµÄ»°£¬¾Í²»ÄÜÓÃÕâ¸ö·½·¨ÁË¡£ÏÂÃæÊÇÒ»¸öÀý×Ó£º
a.aspxµÄC#´úÂë
private void B ......

ASP.NET MVC ÊÓͼ¸ÅÀÀ (C#)

´Ë½Ì³ÌÏòÄãÌṩ ASP.NET MVC ÊÓͼ¼ò½é, ÊÓͼÊý¾Ý, ºÍ HTML Helpers¡£½Ì³Ì×îºó£¬ÄãÓ¦¸Ã»áÀí½âÈçºÎ´´½¨ÐÂÊÓͼ£¬´Ó¿ØÖÆÆ÷´«µÝÊý¾Ýµ½ÊÓͼ£¬ºÍʹÓà use HTML Helpers ÔÚÊÓͼÖÐÉú³ÉÄÚÈÝ¡£
Àí½âÊÓͼ
²»Ïñ ASP.NET »òÕßASP, ASP.NET MVC ²¢²»°üÀ¨ÈκÎÖ±½Ó¶ÔÓ¦Ò³ÃæµÄ¶«Î÷¡£ ÔÚ ASP.NET MVC Ó¦ÓóÌÐòÖУ¬Ó²ÅÌÉϲ¢²»´ ......

C#´úÂëÓëjavaScriptº¯ÊýµÄÏ໥µ÷ÓÃ

C#´úÂëÓëjavaScriptº¯ÊýµÄÏ໥µ÷ÓÃ
ÎÊ£º
1.ÈçºÎÔÚJavaScript·ÃÎÊC#º¯Êý?
2.ÈçºÎÔÚJavaScript·ÃÎÊC#±äÁ¿?
3.ÈçºÎÔÚC#ÖзÃÎÊJavaScriptµÄÒÑÓбäÁ¿?
4.ÈçºÎÔÚC#ÖзÃÎÊJavaScriptº¯Êý?
ÎÊÌâ1´ð°¸ÈçÏ£º
javaScriptº¯ÊýÖÐÖ´ÐÐC#´úÂëÖеĺ¯Êý£º
·½·¨Ò»£º1¡¢Ê×ÏȽ¨Á¢Ò»¸ö°´Å¥£¬ÔÚºǫ́½«µ÷Óûò´¦ÀíµÄÄÚÈÝдÈëbutton_clickÖÐ ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ