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

asp.net ÊüÕÖ²ãÉÏ´«Í¼Æ¬(¶þ½øÖÆ),²¢ÏÔʾ¶þ½øÖÆͼƬ

1.ÉÏ´«¹¦ÄÜ
JS¼ì²é
function hideUpImg()//¹Ø±Õ²ã£¬²¢ÉÏ´«Í¼Æ¬
{
var v=document.getElementById("upImg").value;
var after=v.substring(v.lastIndexOf('.')).toLowerCase();
alert(after);
if(v.length<=0)
{
alert("ÇëÑ¡ÔñͼƬ");
return false;
}
if(after==".jpg"||after==".gif"||after==".png")
{
return true;
}
alert("ͼƬֻÄÜÊÇ.jpg .gif .png¸ñʽ");
document.getElementById("upImg").outerHTML=document.getElementById("upImg").outerHTML;
return false;
}
Ò³Ãæ´úÂ룺
<div id="myDiv" style="display: none;" mce_style="display: none;" class="divshowbottom"> </div>
<div id="upLoadImg" style="top: 200px;left: 300px;display: none;" class="divshowwork">
<div style="width: 100%; height: 20px;background-color: #FF0000; cursor: move;">ÉÏ´«Í¼Æ¬</div>
<p style="text-align: center;" mce_style="text-align: center;">ÇëÉÏ´«Í¼Æ¬</p>
<asp:FileUpload ID="upImg" runat="server" />
<asp:Label ID="lblState" runat="server" ></asp:Label>
<br /><asp:Button ID="btnUpImg" runat="server" Text="ÉÏ´«" OnClick="btnUpImg_Click" /> <input type="button" value="È¡Ïû" id="button_2" />
</div>
ºǫ́´úÂë:
Stream stream = this.upImg.PostedFile.InputStream;
byte[] photo = new byte[upImg.PostedFile.ContentLength];
stream.Read(photo, 0, upImg.PostedFile.ContentLength);

ItemMaster im = new ItemMaster();
im.ItemUid =Convert.ToInt32(s.Split('|')[1]);
im.Drawing = photo;
int upd = ItemMasterBIZ.UpdItemMasterByImg(im);
stream.Cl


Ïà¹ØÎĵµ£º

asp.netÁ´½ÓAccessÊý¾Ý¿â×Ö·û´®ÕýÈ··½·¨

ÔÚweb  configÖР ×÷ÈçÏÂÅäÖãº
<connectionStrings>
    <add name="ydycon" connectionString="Provider=Microsoft.Jet.OLEDB.4.0;
Data Source=|DataDirectory|ydy.mdb" providerName="System.Data.OleDb"/>
 
  </connectionStrings>
ÔÚ.netÎļþÖÐÓ¦ÓÃÁ´½Ó ......

ASP.NET MVC½éÉÜ

The Model-View-Controller (MVC) architectural pattern separates an application into three main components: the model, the view, and the controller. The ASP.NET MVC framework provides an alternative to the ASP.NET Web Forms pattern for creating MVC-based Web applications. The ASP.NET MVC framework is ......

asp.netÑéÖ¤¿Ø¼þ²»Æð×÷ÓõĽâ¾ö°ì·¨

×î½üд³ÌÐòÒ»Ö±³öÎÊÌ⣬ÒÔÇ°Ò»¸öÕ¾Èý¼¸Ìì¾ÍÇáËɸ㶨£¬ÏÖÔÚÒ»¸öÄ£¿é¾­³£¸ã°ëÌ죬NND
ÏÂÎ翪·¢¿áÒ×»¯×±Æ·É̳Ç(http://www.koyee.net)Ò»¸ö±íµ¥Ìá½»¹¦ÄÜÄ£¿é£¬±¾µØÈκÎÎÊÌⶼûÓÐÁË£¬´«µ½·þÎñÆ÷Éϱ¾ÒÔΪûÊÂÁË£¬ºóÀ´Ò»¼ì²éËùÓеÄÑéÖ¤¿Ø¼þ¶¼²»Æð×÷ÓÃÁË£¬Ö±½Ó¶¼Ìá½»¹ýÈ¥ÁË£¬ÓôÃÆ£¬Ô­ÒÔΪ³ÌÐò±»¸Ä´íÁË£¬¼ì²é±¾µØ»¹ÊÇûÈκÎÎÊÌ⣬¼ ......

asp.net ¶¯Ì¬Ìí¼Ó¿Ø¼þ Óë È¡Öµ £¡£¡£¡

Ê×ÏÈ·¨·½ÓÐ3¸ö£¬ÕâÀï¾Í˵2¸öʵÓõġ£¡£¡£
1£¬Ö±½ÓΪ ¿Ø¼þ innerhtml Ìí¼ÓÖµ
2£¬createElement £¨´´½¨COM£©
3£¬ºǫ́ NEW ¿Ø¼þ£¬Ìí¼Ó
ÕâÀï˵Ï 1£¬2 Á½¸ö·¨·½£¡
1£º
¶¯Ì¬Éú³É ×Ö·û´®  string inntext=" <table> <tr> <td style=width:300px;text-align:right; >{0}<input id={1} type=text c ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ