输入选定文件的“已启用"键. [英] Enter key Enabled for a selected pagges.

查看:88
本文介绍了输入选定文件的“已启用"键.的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好,


我在整个应用程序中都已禁用Enter键,即在母版页上

Hello All,


I have Disabled Enter key in whole application, i.e. on Master Page

<Form keydown="falseEnterKey()"></form>.



但是我需要为选定的页面启用Enter键.即某些页面文本框,我希望启用输入键

那我该怎么办,
请给我解决方案.



But i need Enter key enabled for a selected pages. i.e some pages textbox i want entry key enabled

So what i do,
Please give me solution.

推荐答案

@ Madhuri


您可以使用以下httpcontext类来启用falseEnterKey
这里的test.aspx是您要启用密钥的页面

Hi @Madhuri


you can use this following httpcontext class to get enable the falseEnterKey
here test.aspx is the page where you want to enablekey

var page = HttpContext.Current.CurrentHandler as Page;
if (page.Page.ToString().Contains("test_aspx")))
{
enter the code to enable the enter key///////
}
else
{
////////////don't enable
}


希望对您有帮助

谢谢


Hope it will help you

Thanks


由于整个网页的功能不一致,因此您可以在母版页中使用falseEnterKey()功能.是否调用它应该在每个网页中决定.
Since the functionality is not consistent throughout the web pages, you can just have the falseEnterKey() function in your master page. To call it or not should be decided in each web page.


这篇关于输入选定文件的“已启用"键.的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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