摘要:
1. 数据库文件包括: 主数据文件:*.mdf 次要数据文件:*.ndf 日志文件:*.ldf ( l 是 L 的小写) 2.使用T-SQL创建数据库 代码 use master go -----------创建数据库------------ if exists (select * from sysdatabases where name='stuDB') drop database ... 阅读全文
摘要:
ToolbarButton XAML代码如下: <Button x:Class="XCenter.Framework.Client.ToolbarButton" 2 xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" 3... 阅读全文
摘要:
今天在将数据库里的datetime类型数据赋给C#里DateTime类型变量的时候遇到一个问题,那就是数据库里面的datetime数据存在null值。 C#默认不能将null赋给DateTime变量,但是可以使用Nullable类型的DateTime,只需在声明变量的时候在DateTime后加一个?号,如: DateTime? x ; x便可以赋null值。 但是从数据库的datetime类型变为... 阅读全文
摘要:
TextWraping属性,"Wrap"是换行,NoWrap是不换行TextBlock控件内可以放置很多控件,不光是文字<TextBlock TextWraping="Wrap"> <Button>Split</Button> <CheckBox>across</CheckBox> <TextBox>mult... 阅读全文
摘要:
& # 13; (去掉空格)<TextBlock Text="第一行& # 13;第二行"/> 阅读全文
摘要:
用Linq直接查询int[] s = { 1, 5, 8, 9, 3 }; int xxx = (from mm in s select mm).Max(); 阅读全文
摘要:
//今天 DateTime.Now.Date.ToShortDateString(); //昨天,就是今天的日期减一 DateTime.Now.AddDays(-1).ToShortDateString(); //明天,同理,加一 DateTime.Now.AddDays(1).ToShortDateString();//本周(要知道本周的第一天就得先知道今天是星期几,从而得知本周的第一天就是几天... 阅读全文
摘要:
编号 品名 数量 日期 供商1011 a 10 2009-01-01 001 1011 a 1 2009-01-01 002 1011 a 3 2009-01-03 001 1012 b 3 2009-01-01 001 1012 b 5 2009-01-02 003 1012 b 5 2009-01-02 003 我想得到以下结果:编号 品名 数量 日期 供商1011 a 14 2009-01-... 阅读全文
摘要:
OutOfBrowser.xaml<Button x:Name="button" Click="button_Click" Width=100 Height=30></Button>OutOfBrowser.xaml.cspublic OutOfBrowser(){InitializeComponent();this.Loaded+=new RoutedEventHandl... 阅读全文
摘要:
Image.xaml<canvas x:name="LayoutRoot"> <img x:name="imgLogo1" source="Image/logo1.jpg" canvas.top="60" canvas.left="100" canvas.zindex="1" mouseleave="imgLogo1_MouseLeave" mouseenter="imgLogo... 阅读全文