将列转换为int的网格视图 [英] convert column into grid view to int

查看:75
本文介绍了将列转换为int的网格视图的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好
我如何将绑定列转换为int的网格视图
我已将模板提交此文件
Text =<''%#Bind("lastid")%''>我需要按列"lastid" +1
绑定网格视图 对于每行

hi all
how can i convert binding column into grid view to int
i have template filed this
Text=<''%# Bind("lastid")%''> i need to bind grid view by column "lastid" +1
for each row

推荐答案

为什么不直接在查询本身中这样做呢?在查询中传递"LastID + 1",您无需担心.



您可以在绑定网格之前修改数据表.
Why don''t you directly do that in the query itself? Pass on ''LastID+1" in the query and you don''t need to worry about it.

OR

You can modify the datatable before binding the grid.


另一种方法是,您可以在服务器端具有一个公共功能,该功能可以返回修改后的ID,并且可以将其放置为
Another way, you cab have a public function at server side that returns the modified ID and that can be placed as
<%# GetUpdatedId("lastid") %>


这篇关于将列转换为int的网格视图的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆