且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

隐藏选择行问题

更新时间:2023-12-04 12:22:58

你需要更清楚地解释你的启用/选择/禁用要求。

据我所知,你在Panel中有一个GridView。



我不明白你在点击编辑按钮时如何启用你的面板。


这个按钮是否属于GridView?

如果它是你怎么能够ev当面板被禁用时点击按钮?


另一件我不明白的是你提到GridView被禁用了。你在做这个客户端还是服务器端?

如果你正在做这个服务器端那你为什么不检查GridView.Enabled然后...然后相应地应用JavaScript ??


-Frinny
You need to explain your enable/select/disable requirements more clearly.
From what I understand is that you have a GridView in a Panel.


What I don''t understand is how you are enabling your Panel when an Edit button is clicked.

Is this button a part of the GridView?
If it is how are you able to even click the button when the panel is "disabled"??

The other thing I don''t understand is your mentioning of the GridView being disabled. Are you doing this client side or server side?
If you''re doing this server side then why don''t you just check if GridView.Enabled then...and then apply the JavaScript accordingly??

-Frinny


@Frinavale


默认情况下,我将gridview in设置为禁用,以便在不单击面板外部的编辑按钮的情况下无法编辑值。基本上我的网站正在做的是....我在页面的一侧有一个列表。当单击某个人的姓名时...将根据存储在数据库中的记录填充gridview。 gridview实际上已设置为启用,但由于它在面板中,我刚刚使用了一些其他网格视图,并将面板设置为禁用,直到单击面板外部的编辑按钮。我发布的代码的主要问题是,当面板仍然被禁用时,您仍然可以单击记录并选择它们....这会引发事件验证问题。如果我单击编辑按钮,然后选择一个记录,它可以正常工作。基本上我想要的是在按下编辑按钮之前记录不可点击。上面发布的代码在databound_event上,所以我想创建一个接受gridview的方法/函数,并设置这些属性。然后我将把方法/函数放入编辑按钮onclick事件。
@Frinavale
By default, the panel i have the gridview in is set to disabled so that one cannot edit values without clicking the edit button which is outside of the panel. Basically what my site is doing is....I have a list on the side of the page. When one clicks on the name of a person...the gridview becomes populated based on the records stored in a database. The gridview is actually set to enabled but since it is in the panel with a few other gridviews i just used and set the panel to disabled until one clicks the edit button outside of the panel. My main problem with the code i posted is that when the panel is still disabled, you can still click on the records and select them....which throws an eventvalidation problem. If i click the edit button and then select a record, it works fine. Basically what i want is for the records to not be clickable until the edit button has been pressed. The above code posted is on the databound_event so im looking to create a method/function that will accept a gridview and will set these attributes. I will then put the method/function in with the edit button onclick event.


谢谢:)

我现在明白了。
>
我们应该做的是放置一个JavaScript函数,以确保在执行Select函数之前启用面板。


嗯...类似于:
Thank you :)
I understand now.

What we should do is put a JavaScript function in place to make sure that the panel is enabled before executing the Select function.

Hmm...Something like:
展开 | 选择 | Wrap | 行号