2011年9月26日 星期一

MySQL 取最後一筆資料


select * from `boss_record` WHERE `index` = 1 order by `kill_times` limit  1


先用 order by 排序
黃字 1 就是取最後一筆

找程式設計師 千萬別用104 or yes123

來源:http://techblog.insureme.com.tw/2011/09/1041111yes123.html
 

1. 程式設計師論壇,這是要打知名度用的,讓程式社群知道你的公司:
http://www.javaworld.com.tw/jute/
http://jobs.ruby.tw/
http://jobs.inside.com.tw/
2. 去以下社群分享,你會收集到一堆對你科技有興趣程式設計師的聯絡方式:
http://wiki.cloudtw.org/
http://www.taipei-gtug.org/
http://wiki.python.org.tw/
http://ruby.tw/
OSDC
Coscup
HIT(如果你想找黑人)

HTML5 亂七八糟筆記


HTML5 筆記

來源: http://www.w3schools.com/html5/html5_new_elements.asp

New Markup Elements


TagDescription
<article>Specifies independent, self-contained content, could be a news-article, blog post, forum post, or other articles which can be distributed independently from the rest of the site.
文章 微博 什麼 獨立分開?
<aside>For content aside from the content it is placed in. The aside content should be related to the surrounding content
預留 空間 可以放置一些東西?
<command>A button, or a radiobutton, or a checkbox
按鈕之類的     目前只有IE支援   chrome還沒支援
<details>For describing details about a document, or parts of a document
放置文件的 詳細資料  有點像 樹狀結構
<summary>A caption, or summary, inside the details element
<details>的標題
<figure>For grouping a section of stand-alone content, could be a video
放圖片 和圖片資訊的 空間
<figcaption>The caption of the figure section
<figure>的標題
<footer>For a footer of a document or section, could include the name of the author, the date of the document, contact information, or copyright information
放置 文章資訊      ex: 作者 日期資訊 聯絡資料 版權 等.....
<header>For an introduction of a document or section, could include navigation
標頭?
<hgroup>For a section of headings, using <h1> to <h6>, where the largest is the main heading of the section, and the others are sub-headings
標頭?
<mark>For text that should be highlighted
文章的重點部份  (像銀光筆一樣 標記重點)
<meter>For a measurement, used only if the maximum and minimum values are known
進度條!!!     目前只有chrome和 opera支援
<nav>For a section of navigation
放一些 連結用的?
<progress>The state of a work in progress
進度條  (((firefox chrome opera支援
<ruby>For ruby annotation (Chinese notes or characters)
顯示在文字上方  類似註解 或是放入國字的注音符號
<rt>For explanation of the ruby annotation
和<ruby>一樣吧
<rp>What to show browsers that do not support the ruby element
這 還沒搞懂.......
<section>For a section in a document. Such as chapters, headers, footers, or any other sections of the document
又是類似標頭的.....
<time>For defining a time or a date, or both
定義時間 或日期等等.....
<wbr>Word break. For defining a line-break opportunity.
一個單字 過長   可適當調整斷行 還是什麼的?

以上看起來 都是沒什麼作用呢.......是太多人想分這塊大餅嗎......

2011年9月23日 星期五

C# WndProc 攔截系統訊息

轉自 http://www.iteddie.com/2010/10/c_19.html



windows無論你做甚麼動作他都會產生一個訊息
比如說 按下鍵盤,放開鍵盤,移動滑鼠,按下滑鼠,移動視窗,最小化視窗..
所以可以透過覆寫WndProc Method可以處理所有你想處理的訊息~



下列程式碼範例將示範如何覆寫 WndProc 方法以處理 Message 結構中所示的作業系統訊息。在這個範例中處理的 WM_ACTIVATEAPP 作業系統訊息可以讓您知道另一個應用程式將成為作用中的時間。

protected override void WndProc(ref Message m)
{
const int WM_ACTIVATEAPP = 0x001C;
// Listen for operating system messages.
switch (m.Msg)
{
// The WM_ACTIVATEAPP message occurs when the application
// becomes the active application or becomes inactive.
case WM_ACTIVATEAPP:
// The WParam value identifies what is occurring.
appActive = (((int)m.WParam != 0));
// Invalidate to get new text painted.
this.Invalidate();
break;
//case.......more message you want to process
}

base.WndProc(ref m);
}

 

MangoHost Copyright © 2009 Cookiez is Designed by Ipietoon for Free Blogger Template