| 网站首页 | 业界新闻 | 小组 | 威客 | 人才 | 下载频道 | 博客 | 代码贴 | 在线编程 | 编程论坛
欢迎加入我们,一同切磋技术
用户名:   
 
密 码:  
共有 332 人关注过本帖
标题:窗体里面的查看功能没有完善求高手来看下那做了!!!!
只看楼主 加入收藏
MHxn
Rank: 1
等 级:新手上路
帖 子:8
专家分:0
注 册:2013-1-19
结帖率:100%
收藏
 问题点数:0 回复次数:0 
窗体里面的查看功能没有完善求高手来看下那做了!!!!
[local]1[/local] 求助啊  ,这是什么问题啊  我的这个问题是窗体问题!   我的问题就是为什么read没有作用
 if (this.textBox1.Text.Equals(string.Empty))
            {
                MessageBox.Show("请输入花卉名称","提示",MessageBoxButtons.OK,MessageBoxIcon.Information);
            }
            try
            {
                string sql1 = "select name,anothername,propery,price,production from FlowerManagerSys where name like '" + this.textBox1.Text + "%'";
                DataTable dat = db.getSet(sql1).Tables[0];
                dataGridView1.DataSource = dat;
                SqlDataReader data = db.get(sql1);
                if (!dat.Read())
                {
                    MessageBox.Show("此花卉不存在", "提示", MessageBoxButtons.OK, MessageBoxIcon.Information);
                }
            }
            catch (Exception)
            {
                MessageBox.Show("程序错误", "提示", MessageBoxButtons.OK, MessageBoxIcon.Information);
            }
        }
搜索更多相关主题的帖子: price where 
2013-01-24 00:47
快速回复:窗体里面的查看功能没有完善求高手来看下那做了!!!!
数据加载中...
 
   



关于我们 | 广告合作 | 编程中国 | 清除Cookies | TOP | 手机版

编程中国 版权所有,并保留所有权利。
Powered by Discuz, Processed in 0.014043 second(s), 7 queries.
Copyright©2004-2024, BCCN.NET, All Rights Reserved