Senin, 13 Mei 2013

[MS_AccessPros] Re: Combo Box row source search criteria (one or all items)

 

Rohn

You can do this with a UNION query as the combo's RowSource

SELECT Dept, Dept
FROM myTable
UNION
SELECT "*", "<All>"
FROM myTable

Regards,
Bill Mosca, Founder - MS_Access_Professionals
http://www.thatlldoit.com
Microsoft Office Access MVP
https://mvp.support.microsoft.com/profile=C4D9F5E7-BB03-4291-B816-64270730881E
My nothing-to-do-with-Access blog
http://wrmosca.wordpress.com

--- In MS_Access_Professionals@yahoogroups.com, "Rohn" <reverson@...> wrote:
>
> Hi all,
> We cannot seem to figure out how to select the departments from a combo
> box and allow selection of all departments in the combo box when
> desired.
> We have a search Form that provides a start and ending date for a date
> report via a command button or you can select the dates and a
> department combo box and run a report via a different command button.
> They both work fine except for selecting all departments.
> We need to add the ability to select ALL DEPARTMENTS in the combo box
> for printing/viewing but cannot seem to figure out how.
> Contents of the Combo Box:* (we need to add this feature, or something
> like it)AssemblyFabricationPaintWeldEct.
>
> the Search form uses OnOpen to get the last work week dates:Private Sub
> Form_Open(Cancel As Integer) Me![Date_From] = Date - Weekday(Date,
> 2) - 6 Me![Date_To] = Me![Date_From] + 5End Sub
> Any guidance would be appreciated.
>
>
> [Non-text portions of this message have been removed]
>

__._,_.___
Reply via web post Reply to sender Reply to group Start a New Topic Messages in this topic (2)
Recent Activity:
.

__,_._,___

Tidak ada komentar:

Posting Komentar