WPF學習筆記.

來源:互聯網
上載者:User

1.WPF是winform開發web化, xaml及設計器完全類似web開發的設計器.

2.WPF項目裡可以建立winform, 反之不行, 應該是向後相容.

3.Main函數, 應用程式進入點. 建立一個WPF項目,發現裡面有一個App.xaml和MainWindow.xaml檔案,開啟App.xaml.cs也找不到Main()函數,實際上它在App.xaml裡的StartupUri="MainWindow.xaml", 在這裡指定了.

<Application x:Class="WpfApplication1.App"
             xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             StartupUri="MainWindow.xaml">
    <Application.Resources>         
    </Application.Resources>
</Application>

注意, 因為應用程式的入口函數是自動產生的,不用也不要再在App.xaml.cs代碼裡在添加Main函數,否則編譯器會報Main方法已經定義。

 

以後要逐漸補充: Xaml文法, 控制項, 布局, Binding, 屬性, 事件, 命令, 資源, 模板, 繪圖與動畫.

 

推薦資料:

1.<<深入淺出WPF>>.

2.WPF應用程式開發與部署(1)(WPF講座系列--2)
http://www.cnblogs.com/NineFlowers/archive/2008/09/17/1292886.html

 

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.