扩展ASP.NET 2.0内置GridView控件之一
日期:2007年9月16日 作者: 查看:[ 大字体 中字体 小字体]-
border="0" marginwidth="0" marginheight="0" src="http://www.hackhome.com/gg/web/ff_468.html" frameborder="no" width="468" scrolling="no" height="0"> - <script src="http://pagead2.googlesyndication.com/pagead/show_ads.js" type="text/javascript"> </script> name="google_ads_frame" marginwidth="0" marginheight="0" src="http://pagead2.googlesyndication.com/pagead/ads?client=ca-pub-0692289505803928&dt=1206919607750&lmt=1199903354&format=300x250_as&output=html&correlator=1206919607750&channel=6926205886&url=http%3A%2F%2Fwww.hackhome.com%2FInfoView%2FArticle_180228_3.html&color_bg=FFFFFF&color_text=000000&color_link=000060&color_url=008000&color_border=FFFFFF&ad_type=text_image&ref=http%3A%2F%2Fwww.hackhome.com%2FInfoView%2FArticle_180228_2.html&frm=0&cc=100&ga_vid=311617188.1206919608&ga_sid=1206919608&ga_hid=519643682&flash=9.0.47.0&u_h=768&u_w=1024&u_ah=738&u_aw=1024&u_cd=32&u_tz=480&u_his=2&u_java=true" frameborder="0" width="300" scrolling="no" height="250" allowtransparency="allowtransparency">
相关的属性如下:
·GridView控件是具有上下文菜单的,这里的ID设置的就是在ASPX页面上的GridView控件ID
·RightClickedRow:该属性设置上下文菜单。
下图显示了运行结果。
当您在行上单击鼠标右键时弹出Context Menu菜单。这里显示了三个选项:
·Add a new Row:当选择该选项后,将会在记录里出现新建行。
·Delete Row:允许你删除当前右击的行
·Edit Row:运行您设置当前行的模式 为编辑模式
(出处:网侠)