如何将组合框默认值设置为先前选择的值 [英] How to set a combo box default value to the previously selected value

查看:515
本文介绍了如何将组合框默认值设置为先前选择的值的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

Hello All,


我想询问如何将组合框中的默认值设置为MS Access 2003中先前选择的值。 />

我有50个左右可能的项目可以从组合框中选择并滚动它们每个选择时间对于用户来说太耗时。由于大多数时候用户会选择相同的可重复值,因此我尝试将默认值设置为之前选择的值是有意义的!?!?我的逻辑是否正确?


当我尝试这样做时,我转向访问表达式构建器,但是我无法找到正确的表达式来执行此操作?


有什么建议吗?


D

Hello All,

I?d like to make an enquiry as to how to set the default value in a combo box to the previously select value in MS access 2003.

I have 50 or so possible items that can be selected from the combo box and scrolling though them each selection time will be too time consuming for the user. As the majority of the time the user will be selecting the same value repeatable, it makes sense to me to try and set the default value to the previously selected one!?!? Is my logic correct?

When I try to do this I get diverted to accesses expression builder, however I am unable to find the correct expression to do this?

Any advise?

D

推荐答案

拒绝。

查看重复多个记录中字段的值主题。


在组合框的AfterUpdate事件的代码编辑器中,您可以使用它来设置默认值(假设它是文本字段)

In the code editor in the AfterUpdate event for your combobox you can use this to set the default (assuming it''s a text field)

展开 | 选择 | Wrap | 行号


感谢您的快速响应伙伴然而我的问题继续.....


默认值更新为先前选择的值(我使用 ComboBox.DefaultValue =""" " &安培; Me.PartNumbers& """" 解决方案)在第一个命令按钮上单击然后在后续条目上添加任何内容。看来我需要重置事件程序我该怎么做?


谢谢,
Thanks for the quick response guys however my problems continue.....

The default value is updated to the previously selected value (i used the ComboBox.DefaultValue = """" & Me.PartNumbers & """" solution) on the first command button click however on subsequent entries nothing is added. It appears i need to reset the event procedure how do i do this?

Thanks,


这篇关于如何将组合框默认值设置为先前选择的值的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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