Filter

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • amir

    #1

    Filter

    How can I filter again my previous filtered records, I mean when I
    filter an entire I can filter again and again the filtered data.
    Many thanks for your help.

    Amir

  • Ed Robichaud

    #2
    Re: Filter

    You can simply use SelectQuery1 as the datasource of SelectQuery2, then use
    #2 as the datasource of SelectQuery3, etc. When you run Query#n, all the
    underlying queries will be run in sequence.
    -Ed

    "amir" <markid_82@yaho o.comwrote in message
    news:1165999673 .816586.244980@ n67g2000cwd.goo glegroups.com.. .
    How can I filter again my previous filtered records, I mean when I
    filter an entire I can filter again and again the filtered data.
    Many thanks for your help.
    >
    Amir
    >

    Comment

    • amir

      #3
      Re: Filter

      Dear Ed
      This is my query:
      I used adodc & datagrid with this code

      Dim MyQuery as string

      MyQuery = cbo_catagory & " " & cbo_Operator & " '" & text1.text & "' "

      If Text1.Text <"" Then
      Adodc1.Recordse t.Filter = MyQuery
      End If

      So what is your suggetion on this matter. Pls help me.

      Thanks for your reply.

      Amir

      Ed Robichaud wrote:
      You can simply use SelectQuery1 as the datasource of SelectQuery2, then use
      #2 as the datasource of SelectQuery3, etc. When you run Query#n, all the
      underlying queries will be run in sequence.
      -Ed
      >
      "amir" <markid_82@yaho o.comwrote in message
      news:1165999673 .816586.244980@ n67g2000cwd.goo glegroups.com.. .
      How can I filter again my previous filtered records, I mean when I
      filter an entire I can filter again and again the filtered data.
      Many thanks for your help.

      Amir

      Comment

      • Ed Robichaud

        #4
        Re: Filter

        You're not actually creating a filter with your string. What value(s) of
        [category], [operator] or [text] do you want to filter on? Try creating
        your filter with a select query in design mode (and set your criteria for
        those fields); save that query; reference that query in your code:

        If Text1.Text <"" Then
        Adodc1.Recordse t = qryMyQuery
        Adodc1.requery
        End If

        Assuming that "adodc1" is the name of your form/report.

        -Ed


        "amir" <markid_82@yaho o.comwrote in message
        news:1166081626 .242315.163760@ 16g2000cwy.goog legroups.com...
        Dear Ed
        This is my query:
        I used adodc & datagrid with this code
        >
        Dim MyQuery as string
        >
        MyQuery = cbo_catagory & " " & cbo_Operator & " '" & text1.text & "' "
        >
        If Text1.Text <"" Then
        Adodc1.Recordse t.Filter = MyQuery
        End If
        >
        So what is your suggetion on this matter. Pls help me.
        >
        Thanks for your reply.
        >
        Amir
        >
        Ed Robichaud wrote:
        >You can simply use SelectQuery1 as the datasource of SelectQuery2, then
        >use
        >#2 as the datasource of SelectQuery3, etc. When you run Query#n, all the
        >underlying queries will be run in sequence.
        >-Ed
        >>
        >"amir" <markid_82@yaho o.comwrote in message
        >news:116599967 3.816586.244980 @n67g2000cwd.go oglegroups.com. ..
        How can I filter again my previous filtered records, I mean when I
        filter an entire I can filter again and again the filtered data.
        Many thanks for your help.
        >
        Amir
        >
        >

        Comment

        Working...