2014年9月10日 星期三

C# 控件:Login的使用

Login控件的使用,可參考下列網站:

http://www.dotblogs.com.tw/kevin8977/archive/2009/08/21/10166.aspx

錯誤訊息:名稱 'FormsAuthentication' 不存在於目前內容中

在製作登入機制時,加入↓↓↓↓↓↓

FormsAuthentication.RedirectFromLoginPage(Login1.UserName, true);

發生了錯誤訊息:【名稱 'FormsAuthentication' 不存在於目前內容中】

解決方法是加入use即可,


using System.Web.Security;
using System.Security.Cryptography;


ASP.NET 4.5 加入 Login 控制項產生錯誤訊息

ASP.NET 4.5 加入 Login 控制項產生錯誤訊息,訊息如下:

WebForms UnobtrusiveValidationMode 需要 'jquery' 的 ScriptResourceMapping。請加入 ScriptResourceMapping 命名的 jquery (區分大小寫)。

因為 ASP.NET 4.5 採用了不同的 Client Side 驗證方式。

解決方式只要在Web.config檔案中加入

<configuration>
  <appSettings>
    <add key="ValidationSettings:UnobtrusiveValidationMode" value="None" />
  </appSettings>
</configuration>


即可以解決此問題。

參考來源:

http://www.allenkuo.com/GenericArticle/view1441.aspx
http://www.webcodeexpert.com/2013/06/how-to-solve-webforms.html

2014年8月23日 星期六

GridView 中的CheckBox全選

        $(document).ready(function () {
            $('input[id="btn_SelectAll"]').click(function () {
                var tbl = $('table[id ="myTable"]');
                tbl.each(function () {
                    $(this).find('tr').each(function () {
                        $(this).find('td').each(function () {
                            $(this).find('input[type="checkbox"]').attr('checked', false);
                        })
                    })
                })
            })
      })

參考:http://bigone2000.pixnet.net/blog/post/56715490-%E4%BB%A5jquery%E5%AF%A6%E4%BD%9Ccheckbox%E5%85%A8%E9%81%B8%E5%8A%9F%E8%83%BD

2014年5月17日 星期六

mysql workbench 無法開啟

mysql workbench 無法開啟,原因是必須得安裝下列兩個軟體才可以運行。


1. .netFramework 4.0
2. Microsoft Visual C++ 2010 Redistributable Package (x86)