1
所以我張貼的問題前些天有關需要有一個「全選」選項被添加到2個ComoBoxes的訪問形式。我能夠使用聯合將選項添加到其中的2個選項中。但是,這些選項目前還沒有做到。我發現,從組合框的形式爲參數,這是我需要在選項添加到選擇所有,但我沒有線索再次盯着它幾個小時後查詢。如何在Microsoft Access中組合框<Select All>添加功能形成
數據庫不是我寫的,這是大約10歲,並給了我增加一些新的功能。我已經這樣做了,主人抱怨說「全選」按鈕從來沒有工作過。經過研究,這些按鈕具有VB腳本,用於清除組合框輸入爲無效值。因爲我已經將選項添加到ComboBox本身,所以我正在計劃廢除這些。
的SQL查詢讀取組合輸入如下所示:
PARAMETERS [Forms]![ReportCentre]![cboTreatmentType] Short, [Forms]![ReportCentre]! [cboTreatmentDate] Short;
SELECT addresses.*,
[firstname] & "" & [lastname]
AS Name,
[street] & "," & [suburb] & "" & [stateorprovince] & "" & [postalcode]
AS
Address
FROM addresses
WHERE (((addresses.treatmentid) = [forms] ! [reportcentre] !
[cbotreatmenttype].[Value])
AND ((addresses.treatmentdate) = [forms] ! [reportcentre] !
[cbotreatmentdate].[Value])
AND ((addresses.birthmonth) LIKE [forms] ! [reportcentre] !
[txtbirthmonth].[Value]
& "*"))
OR (((addresses.treatmentid) IS NULL)
AND
((addresses.treatmentdate) = [forms] ! [reportcentre] !
[cbotreatmentdate].[Value])
AND ((addresses.birthmonth) LIKE [forms] ! [reportcentre] !
[txtbirthmonth].[Value]
& "*"))
OR (((addresses.treatmentid) = [forms] ! [reportcentre] !
[cbotreatmenttype].[Value])
AND ((addresses.treatmentdate) IS NULL)
AND ((addresses.birthmonth) LIKE [forms] ! [reportcentre] !
[txtbirthmonth].[Value]
& "*"))
OR (((addresses.treatmentid) IS NULL)
AND ((addresses.treatmentdate) IS NULL)
AND ((addresses.birthmonth) LIKE [forms] ! [reportcentre] !
[txtbirthmonth].[Value]
& "*"))
OR (((addresses.treatmentid) IS NULL)
AND
((addresses.treatmentdate) = [forms] ! [reportcentre] !
[cbotreatmentdate].[Value])
AND ((addresses.birthmonth) IS NULL))
OR (((addresses.treatmentid) = [forms] ! [reportcentre] !
[cbotreatmenttype].[Value])
AND ((addresses.treatmentdate) IS NULL)
AND ((addresses.birthmonth) IS NULL))
OR (((addresses.treatmentid) = [forms] ! [reportcentre] !
[cbotreatmenttype].[Value])
AND
((addresses.treatmentdate) = [forms] ! [reportcentre] !
[cbotreatmentdate].[Value])
AND ((addresses.birthmonth) IS NULL));
我知道這是混亂的,很難理解,這就是爲什麼即時通訊尋求幫助。我如何獲得驗證兩個ComboBoxes的「全選」選項?