什么是CT100,如何改名? [英] What is ct100 and how do I rename it?

查看:291
本文介绍了什么是CT100,如何改名?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在.NET 4.0中的工作,它似乎仍然我的所有输入控件具有属性名称,与开头的值 CT100 $ ...。

Working in .net 4.0, it still seems all my input controls have the attribute 'name', with a value that begins 'ct100$...'.

有什么办法来重新命名呢?

Is there any way to rename this?

我已经走了一路上扬的控制层次结构,给每一个控制一个ID,并设置其的ClientIDMode 静态'无果,甚至页面上最早的控件仍继承了preFIX。

I've gone all the way up the control hierarchy, and given each control an ID and set its clientidmode to 'Static' to no avail, even the 'earliest' controls on the page still inherit the prefix.

推荐答案

这是母版页的ID。我加入改变它 Page_Init 我的母版而设置其ID:

This is the master page's ID. I change it by adding a Page_Init to my masterpage which sets its id:

Private Sub InitSub(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Init
    ID = "master"
End Sub

此ID通常是空/空,因此,当它呈现它,它生成一个ID(起始CT100和上升)

This ID is normally empty/null so when it renders it it generates an id (starting at ct100 and going up)

就像@Scott斯塔福德说,保持短,因为它的$页页码$ pfixes每一个客户端ID。

Like @Scott Stafford said, keep it short because it prefixes every client id on your page.

我用像姆比奥,mHome等。

I use words like "mBio", "mHome", etc..

这篇关于什么是CT100,如何改名?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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