@好处多多

@好处多多
1.文件路径
 strFileFrom="\\172.16.20.12\e$\CCL_Development\ProExcelTest\Engg_Index_DFS\Report"
这种形式的在C#中会报错.
解决方法:
 strFileFrom="\\\\172.16.20.12\\\e$\\\CCL_Development\\\ProExcelTest\\\Engg_Index_DFS\\\Report"
 strFileFrom=@"\\172.16.20.12\e$\CCL_Development\ProExcelTest\Engg_Index_DFS\Report"

2.程序中写SQL语句
一般方法:
            string strSQL = "SELECT id,title,note,stime FROM tabnews ";
            strSQL += "WHERE title like '%abc%' ";
修改后:
            string strSQL = @"SELECT id,title,note,stime FROM tabnews
            WHERE title like '%abc%' ";

posted on   ★金★  阅读(115)  评论(0编辑  收藏  举报

导航

< 2006年7月 >
25 26 27 28 29 30 1
2 3 4 5 6 7 8
9 10 11 12 13 14 15
16 17 18 19 20 21 22
23 24 25 26 27 28 29
30 31 1 2 3 4 5
点击右上角即可分享
微信分享提示