如何清除下一个条目的表单控件 [英] How to Clear Form Controls for Next Entry

查看:68
本文介绍了如何清除下一个条目的表单控件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好


我想你最简单的查询。这里是:


我有一个数据表格。一旦用户完成并保存了第一个条目并想要创建一个新条目,我希望他们点击一个标有新条目或其他东西,然后清除所有填充的表单控件准备好新的antry。


我在网上发现了一些零散的信息,但没有什么可以帮助我的。类似的东西:Sub Clear_Form()。


不知道怎么做。


任何帮助都会像往常一样受到赞赏。


谢谢

Hi All

A simple query I suppose for most fo you. Here goes:

I have a form for data antry. Once the user has completed and saved the first entry and want to create a new one, I would want them to click on a button that says " New Entry" or something, which then clears all populated form controls ready for a new antry.

I have found some fragmented information on the web, but nothing to help me out. Something like : Sub Clear_Form().

Not sure how to do this.

Any help will be much appreciated as usual.

Thanks

推荐答案

展开 | 选择 | Wrap | 行号


一些非常简单的事情就是将控制按钮放入表单中。在表单的设计模式下,只需从工具箱中选择控制按钮选项,访问将引导您完成剩下的工作并为您编写VBA代码!
something that''s really simple is to just place a control button into the form. Simply choose the control button option from the toolbox when in design mode for the form and access will walk you through the rest and write the VBA code for you!


您好MSeda和vkong85


感谢您的回复。 MSeda,我认为表格的代码和所有内容都太多了,无法在此发布。表单本身有34个字段,背后有很多代码。当然,无论你的代码是什么,都必须有一些代码清空表单上的所有控件?


vkong85,我试过Access的添加新记录按钮,但它不起作用。似乎它缺少一个清空所有表单控件的触发器。
Hi there MSeda and vkong85

Thank you both for your replies. MSeda, I think the code and everything for the form will be too much to post here. The form itself have 34 fields and there is quite a lot of code behind it. Surely there must be some code that empties all controls on a form regardless of your code?

vkong85, I have tried Access''s Add New Record button, but it does not work. Seems like it is missing a trigger to empty all form controls.


这篇关于如何清除下一个条目的表单控件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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