Hi,
First, sorry for my english, I'm french... I do my best I promise!
I have a subform containing details about Kits to mount (for production purposes).
Several of these kits share parts with other and I made a query to identify that.
So we have a subform with my kits and their details:
Kit A, etc..., etc...
Kit B
Kit C
etc...
I have a query which identify kits sharing parts:
Main_Kit: Kit A ---- Sharing Kit: Kit A obviously!
Kit A ---- Kit B
Kit A ---- Kit D
Kit C ---- Kit C
Kit C ---- Kit E
That query is filtered by the subform as criteria for Main_Kit :
[Forms]![frm_Production01].[Form]![q10_KitsToProduced_GroupBy_subform].[Form]![Kit]
By cliking on a kit on my subform (datasheet view) I want to filter that subform with the related sharing parts kits. And be able to unfiltered and apply the filter on another kit.
For now i created an unbound textbox on my subform with a click event to filter my kit based on the query:
Private Sub Text30_Click()
Dim strFilter As String
strFilter = "[Kit] In('" & "[q27_KitsWithSharedParts_2]![Kit_Number]" & "')"
Me.Filter = strFilter
Me.FilterOn = True
End Sub
(The field Kit or Kit Number is not a number but text.)
So, my problem is thats not working, resulting on a empty subform.
Do you have any idea on how to do a such thing?
Thank you very much in advance.
First, sorry for my english, I'm french... I do my best I promise!
I have a subform containing details about Kits to mount (for production purposes).
Several of these kits share parts with other and I made a query to identify that.
So we have a subform with my kits and their details:
Kit A, etc..., etc...
Kit B
Kit C
etc...
I have a query which identify kits sharing parts:
Main_Kit: Kit A ---- Sharing Kit: Kit A obviously!
Kit A ---- Kit B
Kit A ---- Kit D
Kit C ---- Kit C
Kit C ---- Kit E
That query is filtered by the subform as criteria for Main_Kit :
[Forms]![frm_Production01].[Form]![q10_KitsToProduced_GroupBy_subform].[Form]![Kit]
By cliking on a kit on my subform (datasheet view) I want to filter that subform with the related sharing parts kits. And be able to unfiltered and apply the filter on another kit.
For now i created an unbound textbox on my subform with a click event to filter my kit based on the query:
Private Sub Text30_Click()
Dim strFilter As String
strFilter = "[Kit] In('" & "[q27_KitsWithSharedParts_2]![Kit_Number]" & "')"
Me.Filter = strFilter
Me.FilterOn = True
End Sub
(The field Kit or Kit Number is not a number but text.)
So, my problem is thats not working, resulting on a empty subform.
Do you have any idea on how to do a such thing?
Thank you very much in advance.