使用2个组合框填充子表单 [英] Using 2 Combo boxes to populate a Subform

查看:55
本文介绍了使用2个组合框填充子表单的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

首先,我是Access的完全新手。我使用它可能有六次,我的所有数据库知识都在Oracle上。


我正在Access 2003中构建一个数据库/表单。我正试图让它从一个组合框中选择一个位置,并从另一个组合框中选择一个日期组合框,并为子窗体填充所选的每个日期/位置的正确数据。我不太确定如何解决这个问题,但我一直在阅读,可能是使用命令按钮来执行代码。


更多关于我想要做什么的信息。我正在尝试选择站点位置(位置)和日期(日期),并让子表单填充该日期在该站点关闭的每个员工。做这个的最好方式是什么?代码是否与我在Oracle中执行的相同?


我已经收到了一本Access邮件,因此我可以学习它,但如果我可以尽快完成这一点工作。提前谢谢。

First off, I am a complete newbie to Access. I''ve used it maybe a half dozen times, all my database knowledge is with Oracle.

I''m building a database/form in Access 2003. I''m trying to get it so that I can select a Location from one combo box, and a date from another combo box, and have a Subform populate with the correct data for each date/location selected. I''m not really sure how to go about this, but I''ve been reading maybe using a command button to do the code execution.

More info on what i''m trying to do. I"m trying to select a Site location (Location), and the Date (Date), and have the subform populate each employee that is off at that site on that date. What is the best way to do this? And would the code be the same as if i were to do it in Oracle?

I''ve got a Access book coming in the mail so i can learn it, but if i can get this little bit working ASAP that would be great. Thank-you in advance.

推荐答案

另外


我有3个表日期(每周有一个日期),休假(日期/员工姓名/一般/休假时间),位置(站点位置)。日期和位置也是组合框。
Also

I have 3 tables Date(has each date for the week), Time-Off(date/employee name/general/location for time off), Location(site location). Date, and location are combo boxes as well.



另外


我有3张桌子日期(每周的每个日期),休息时间(日期/员工姓名/一般/休假时间位置),位置(站点位置)。日期和位置也是组合框。
Also

I have 3 tables Date(has each date for the week), Time-Off(date/employee name/general/location for time off), Location(site location). Date, and location are combo boxes as well.




第三个组合框的行源应该是这样的:



The Row Source of the third combo box should be something like:

展开 | 选择 | Wrap | 行号


我想我可能已经解释了自己,或者我可能只是不太了解你。


我的表格看起来像这样


XXxxXX< - 组合框(位置)

XXxxXX< ; ---组合框(日期)

XXxxxXX< ----子表单/子报表(Time-off)(应该从此表中显示员工姓名等)


每个组合框都是从表中填充的。子窗体应该有一个组合框的查询结果。


那么我需要添加另一个组合框吗?也许我只是没有正确理解你。
I think I may have over explained myself, or maybe I''m just not quite understanding you right.

My form looks something like this

XXxxXX <-- Combo Box (Location)
XXxxXX <--- Combo Box (Date)

XXxxxXX <---- Subform/Subreport ( Time-off) (Should show the employee name etc. from this table)

Each Combo Box is populated from a table. And the subform should have a query result from the combo boxes.

So should i need to add another combo box? Again maybe im just not understanding you correctly.


这篇关于使用2个组合框填充子表单的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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