原创 WPF中設置DataGrid中DataGridColumn列的普通樣式和編輯樣式

DataGridColumn的派生類:   一般情況下DataGridBoundColumn和DataGridComboBoxColumn足以滿足多數列的樣式,如果需要自定義列樣式,則可以使用DataGridTemplateC

原创 ListView之BaseAdapter的使用

      前言         話說開發用了各種Adapter之後感覺用的最舒服的還是BaseAdapter,儘管使用起來比其他適配器有些麻煩,但是使用它卻能實現很多自己喜歡的列表佈局,比如ListView、GridView、Gal

原创 Bitmap to BitmapSource

When I started to convert my application from WinForms to WPF, I quickly reached the point where I needed to use my S

原创 wpf獲取屏幕座標

WPF編程時,我們經常使用Mouse.GetPosition(IInputElement relativeTo)或MouseEventArgs.GetPosition(IInputElement rela

原创 android中LayoutInflater的使用

 Inflater英文意思是膨脹,在Android中應該是擴展的意思吧。 LayoutInflater的作用類似於 findViewById(),不同點是LayoutInflater是用來找layout文件夾下的xml佈局文件,並且實例化

原创 C# List和String互相轉換

List轉字符串,用逗號隔開 List<string> list = new List<string>(); list.Add("a"); list.Add("b"); list.Add("c"); //MessageBox.Show(l

原创 Android HttpGet和HttpPost設置超時

HttpPost: private Runnable runnable = new Runnable() { @Override public void run() { String

原创 WPF中設置DataGrid的一些樣式

<Window.Resources>       <Style TargetType="DataGrid">           <!--拖動改變單元格大小-->           <Setter Property="CanUserR