77范文网 - 专业文章范例文档资料分享平台

3源代码-XX系统V1[1].0(5)

来源:网络收集 时间:2019-03-15 下载这篇文档 手机版
说明:文章内容仅供预览,部分内容可能不全,需要完整文档或者需要复制内容,请下载word后使用。下载word有问题请添加微信号:或QQ: 处理(尽可能给您提供完整文档),感谢您的支持与谅解。点击这里给我发消息

XXXX系统V1.0 20

else dr[0][\ if (e.NewValues[\ dr[0][\

else dr[0][\ if (e.NewValues[\ dr[0][\ else dr[0][\ if (e.NewValues[\ dr[0][\ else dr[0][\ if (e.NewValues[\ dr[0][\

else dr[0][\ dr[0][\ if (e.NewValues[\ dr[0][\

else dr[0][\ dr[0][\ if (e.NewValues[\ dr[0][\

else dr[0][\ if (e.NewValues[\ dr[0][\

else dr[0][\ //改变了所属建筑 更改电表全称

if (Session[\

Session[\ {

//但没有更新电表全称

if (e.NewValues[\e.OldValues[\ {

//更改电表全称

dr[0][\e.NewValues[\ }

else dr[0][\自行更改了 等于更改值

}

else dr[0][\ dr[0][\ if (Session[\ {

dr[0][\ Session[\ }

dr[0][\ if (Session[\ {

dr[0][\ Session[\ }

if (e.NewValues[\

XXXX系统V1.0 21

dr[0][\

else dr[0][\ if (e.NewValues[\ dr[0][\

else dr[0][\ if (e.NewValues[\ dr[0][\

else dr[0][\ }

return true; }

#endregion #endregion

#region ASPxGridView验证

protected void ASPxGridView1_ParseValue(object sender, DevExpress.Web.Data.ASPxParseValueEventArgs e) {

if (e.FieldName.Equals(\ {

if (e.Value == null || !(Regex.IsMatch(e.Value.ToString(), @\

throw new Exception(\电表通讯地址不能为空且只能为数字!请重新填写.\

else if (e.Value.ToString().Trim().Length > 12)

throw new Exception(\电表通讯地址应为12位以内数字组成!\ }

if (e.FieldName.Equals(\ {

if (e.Value == null || !(Regex.IsMatch(e.Value.ToString(), @\

throw new Exception(\倍率不能为空且只能为数字!请重新填写.\ }

if (e.FieldName.Equals(\ {

if (e.Value == null || !(Regex.IsMatch(e.Value.ToString(), @\ {

throw new Exception(\平电价不能为空且只能为数字!\ } }

if (e.FieldName.Equals(\ {

if (e.Value != null && !(Regex.IsMatch(e.Value.ToString(), @\ {

throw new Exception(\尖电价只能为数字!请重新填写.\ } }

if (e.FieldName.Equals(\ {

if (e.Value != null && !(Regex.IsMatch(e.Value.ToString(), @\ {

throw new Exception(\峰电价只能为数字!请重新填写.\

XXXX系统V1.0 22

} }

if (e.FieldName.Equals(\ {

if (e.Value != null && !(Regex.IsMatch(e.Value.ToString(), @\ {

throw new Exception(\谷电价只能为数字!请重新填写.\ } }

if (e.FieldName.Equals(\ {

if (e.Value != null && !(Regex.IsMatch(e.Value.ToString(), @\ throw new Exception(\初始电量只能为数字!请重新填写.\ }

if (e.FieldName.Equals(\ {

if (e.Value != null && !(Regex.IsMatch(e.Value.ToString(), @\

throw new Exception(\手机号码应为11位数字组成!请重新填写.\ else if (e.Value != null && e.Value.ToString().Length != 11)

throw new Exception(\手机号码应为11位数字组成!请重新填写.\ }

if (e.FieldName.Equals(\ {

int yxrs = Convert.ToInt32(e.Value);

if (e.Value != null && !(Regex.IsMatch(e.Value.ToString(), @\

throw new Exception(\用电人数应为正整数!请重新填写.\ else if (e.Value != null && yxrs > 32767)

throw new Exception(\用电人数不得大于32767!请重新填写.\ }

if (e.FieldName.Equals(\ {

if (e.Value != null && !(Regex.IsMatch(e.Value.ToString(), @\ throw new Exception(\异常预警电量只能为数字!请重新填写.\ }

if (e.FieldName.Equals(\ {

if (e.Value != null && !(Regex.IsMatch(e.Value.ToString(), @\ throw new Exception(\换表倍率只能为数字!请重新填写.\ }

if (e.FieldName.Equals(\ {

if (e.Value != null && !(Regex.IsMatch(e.Value.ToString(), @\ {

throw new Exception(\换表末电量只能为数字!请重新填写.\ } }

if (e.FieldName.Equals(\ {

if (e.Value != null && (Regex.IsMatch(e.Value.ToString(),

XXXX系统V1.0 23

@\

throw new Exception(\负责人只能由汉字、数字、大小写字母组成!请重新填写.\ }

if (e.FieldName.Equals(\ {

if (e.Value != null && (Regex.IsMatch(e.Value.ToString(), @\

throw new Exception(\电表名称只能由汉字、数字、大小写字母组成!请重新填写.\ } }

protected void ASPxGridView1_RowValidating(object sender, DevExpress.Web.Data.ASPxDataValidationEventArgs e) {

//int DBSL = Convert.ToInt16(DbOpt.ExecuteScalar(\DNCJJG..B_DBXX where WGBH='\ //if (DBSL > 32) //{

// e.RowError = \此网关下的电表数量已达到最大限度(32个),不能再增加!请在另一网关下增加或先新建网关。\ // return; //}

int dfl = 0;

dfl = Convert.ToInt16(e.NewValues[\多费率 如果为1则选中 int YCKZ = 0;

YCKZ = Convert.ToInt16(e.NewValues[\异常控制值 1为选中

if (e.NewValues[\

Encoding.Default.GetByteCount(e.NewValues[\ {

AddError(e.Errors, ASPxGridView1.Columns[\电表名称必须填写且不能超过100个字符!\ }

if (dfl == 1 && e.NewValues[\ {

AddError(e.Errors, ASPxGridView1.Columns[\在多费率状态下尖电价必须填写!\ }

if (dfl == 1 && e.NewValues[\ {

AddError(e.Errors, ASPxGridView1.Columns[\在多费率状态下峰电价必须填写!\ }

if (dfl == 1 && e.NewValues[\ {

AddError(e.Errors, ASPxGridView1.Columns[\在多费率状态下谷电价必须填写!\ }

if (e.NewValues[\ {

AddError(e.Errors, ASPxGridView1.Columns[\所属网关必须选择!\

XXXX系统V1.0 24

}

if (e.NewValues[\ {

AddError(e.Errors, ASPxGridView1.Columns[\用电性质必须选择!\

}

if (e.NewValues[\ {

AddError(e.Errors, ASPxGridView1.Columns[\用电类型必须选择!\

}

if (e.NewValues[\ {

AddError(e.Errors, ASPxGridView1.Columns[\父表名称必须选择!\

}

if (e.NewValues[\ {

AddError(e.Errors, ASPxGridView1.Columns[\所属建筑必须选择!\

}

if (e.NewValues[\ {

AddError(e.Errors, ASPxGridView1.Columns[\所属部门必须选择!\

}

if (e.NewValues[\ {

AddError(e.Errors, ASPxGridView1.Columns[\异常控制必须选择!\

}

if (e.NewValues[\ {

AddError(e.Errors, ASPxGridView1.Columns[\状态必须选择!\ }

if (e.NewValues[\

Encoding.Default.GetByteCount(e.NewValues[\ {

AddError(e.Errors, ASPxGridView1.Columns[\负责人名称过长!应为30个字符以内。\ }

if (e.NewValues[\

Encoding.Default.GetByteCount(e.NewValues[\ {

AddError(e.Errors, ASPxGridView1.Columns[\安装地址内容过长!应为50个字符以内。\ }

if (e.NewValues[\

Encoding.Default.GetByteCount(e.NewValues[\ {

AddError(e.Errors, ASPxGridView1.Columns[\固话号码过长!应为20个字符以内。\ }

百度搜索“77cn”或“免费范文网”即可找到本站免费阅读全部范文。收藏本站方便下次阅读,免费范文网,提供经典小说综合文库3源代码-XX系统V1[1].0(5)在线全文阅读。

3源代码-XX系统V1[1].0(5).doc 将本文的Word文档下载到电脑,方便复制、编辑、收藏和打印 下载失败或者文档不完整,请联系客服人员解决!
本文链接:https://www.77cn.com.cn/wenku/zonghe/524186.html(转载请注明文章来源)
Copyright © 2008-2022 免费范文网 版权所有
声明 :本网站尊重并保护知识产权,根据《信息网络传播权保护条例》,如果我们转载的作品侵犯了您的权利,请在一个月内通知我们,我们会及时删除。
客服QQ: 邮箱:tiandhx2@hotmail.com
苏ICP备16052595号-18
× 注册会员免费下载(下载后可以自由复制和排版)
注册会员下载
全站内容免费自由复制
注册会员下载
全站内容免费自由复制
注:下载文档有可能“只有目录或者内容不全”等情况,请下载之前注意辨别,如果您已付费且无法下载或内容有问题,请联系我们协助你处理。
微信: QQ: