Results 1 to 3 of 3
  1. #1
    ishchopra is offline Novice
    Windows XP Access 2007
    Join Date
    Aug 2011
    Posts
    5

    How to Report through Form

    Hello Experts,



    I am zero level in Access and trying to create a simple form based on Query.

    I have one query which have three columns

    Offer_ID
    Week_Won
    Week_Num

    Now this query shows consolidated result, what i am looking is to design a form which inputs Week_Num from user and only return respective week values.


    For instance : form should have two fields and one button

    Week_Num From: _____
    Week_Num To: _____

    BUTTON -


    first user will enter the from week_num and then To week_num after clicking the button it should show the records belong to user inputs.

    Can somebody help me to write a VBA code for the button ?

    any help is appreciated

    Cheers !

  2. #2
    ETCallHome is offline Advanced Beginner
    Windows 7 64bit Access 2007
    Join Date
    Mar 2011
    Location
    Limpopo, South Africa
    Posts
    48
    Hi,

    You will need to give a little bit more than this... post the actual field names you are using and the table/query name, and I will try and create some code for you to use to accomplish you results.

  3. #3
    ishchopra is offline Novice
    Windows XP Access 2007
    Join Date
    Aug 2011
    Posts
    5
    Thankyou so much for replying:
    SELECT A.offer_id, A.week_won,A.Week_num
    FROM TBL_Raw_Wins_Week28 AS A LEFT JOIN TBL_Raw_Wins_Week29 AS B ON A.offer_ID=B.offer_ID
    WHERE B.offer_ID Is Null and A.offer_Id <> "";

    union all

    SELECT A.offer_id, A.week_won,A.Week_num
    FROM TBL_Raw_Wins_Week29 AS A LEFT JOIN TBL_Raw_Wins_Week30 AS B ON A.offer_ID=B.offer_ID
    WHERE B.offer_ID Is Null and A.offer_Id <> "";

    union all

    SELECT A.offer_id, A.week_won,A.Week_num
    FROM TBL_Raw_Wins_Week30 AS A LEFT JOIN TBL_Raw_Wins_Week31 AS B ON A.offer_ID=B.offer_ID
    WHERE B.offer_ID Is Null and A.offer_Id <> "";

    union all

    SELECT A.offer_id, A.week_won,A.Week_num
    FROM TBL_Raw_Wins_Week31 AS A LEFT JOIN TBL_Raw_Wins_Week32 AS B ON A.offer_ID=B.offer_ID
    WHERE B.offer_ID Is Null and A.offer_Id <> "";

    UNION ALL

    SELECT A.offer_id, A.week_won,A.Week_num
    FROM TBL_Raw_Wins_Week32 AS A LEFT JOIN TBL_Raw_Wins_Week33 AS B ON A.offer_ID=B.offer_ID
    WHERE B.offer_ID Is Null and A.offer_Id <> "";
    ================================================== ==================

    Table Names :

    TBL_Raw_Wins_Week28
    TBL_Raw_Wins_Week29
    TBL_Raw_Wins_Week30
    TBL_Raw_Wins_Week31
    TBL_Raw_Wins_Week32
    TBL_Raw_Wins_Week33


    Please let me know if you need more information..

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Replies: 1
    Last Post: 07-15-2011, 10:59 PM
  2. Replies: 4
    Last Post: 12-13-2010, 05:33 PM
  3. Form Or Report
    By a10sgoddess in forum Forms
    Replies: 11
    Last Post: 09-29-2010, 09:50 AM
  4. Form OR Report???
    By p_1800 in forum Access
    Replies: 2
    Last Post: 06-03-2009, 02:34 PM
  5. Replies: 1
    Last Post: 03-02-2009, 11:54 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums