如何在没有“锁定”的情况下阻止对组合框的任何输入它? [英] How can I prevent any input to a Combo Box without "Locking" it?

查看:40
本文介绍了如何在没有“锁定”的情况下阻止对组合框的任何输入它?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好,


我有一个问题,我刚才意识到我似乎可以自己搞清楚...


我在表单上有几个组合框,它们都链接到不同的表。每个组合框都有以下设置:


限制列表 - 是

允许值列表编辑 - 否


然而,只需将光标放在组合框中,您就可以单击并编辑所选的任何内容...是否有办法锁定?组合框,这是不可能的,但仍然允许用户进行选择?


只需切换锁定即可。框的选项为是阻止用户进行选择,我无法看到其他地方可以更改此选项。


在此先感谢,我感谢所有的帮助!

Hello all,

I have an issue that I just realized that I can seem to figure out on my own...

I have a few combo boxes on a form that are all linked to different tables. Each combo box has the following settings:

Limit To List - Yes
Allow Value List Edits - No

However simply placing the cursor in the combobox allows you to click and edit whatever is chosen...is there a way to "Lock" the combo box so that this is not possible but with still allowing the user to make a selection?

Simply switching the "Locked" option for the box to "Yes" prevents the user from making a selection and I can''t see anywhere else where this option could be changed.

Thanks in advance, I appreciate all the help!

推荐答案

我为您创建了一个示例数据库,以帮助您解决此问题。你必须问自己的一件事是,你是否希望只使用它的人只能选择一次?


我假设没有,并在组合框旁边创建了一个按钮来重置框。从下拉列表中选择信息后,您无法删除或更改信息,但如果您想要返回并更改某些内容,只需按下撤消按钮即可进行新选择。


希望这会有所帮助:D





I created a sample database for you to help you on this matter. The one thing you have to ask yourself is do you want the person using it to only be allowed to select something once?

I assumed no and created a button next to the combo box to reset the box. You can not delete or change the information once you select it from the drop down but if you wanted to go back and change something you just press the undo button and then you can make a new selection.

hope this helps :D
附加文件 < td> LockingCombo.zip (9.9 KB,956 views)
Attached Files
LockingCombo.zip (9.9 KB, 956 views)


如果你将limit设置为list,那么如果你输入一个不同的值,它应该显示一个不在列表中的错误框并返回到组合框?
If you set limit to list then if you type in a different value it should show an errorbox not in list and return you to the combobox?


@slenish - 感谢提供样本,虽然我并不担心用户更改选择,因为我关于用户能够将光标放在组合框字段中并输入


@malcolmk - 有李如果用户(无论出于何种原因)进行更改,mit To List会提示错误消息,但是我希望完全避免这个过程......
@slenish - thanks for providing the sample, though I''m not so much worried about the user changing the selection as I am about the user being able to place the cursor in the combobox field and type away

@malcolmk - having the Limit To List does prompt the error message if the user (for whatever reason) makes changes, however I was hoping to avoid that process altogether...


这篇关于如何在没有“锁定”的情况下阻止对组合框的任何输入它?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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