+ Reply to Thread
Results 1 to 7 of 7

after run advanced filter, only shows headline or show al without filter

  1. #1
    Registered User
    Join Date
    04-01-2009
    Location
    Australia
    MS-Off Ver
    Microsoft Professional 2010 plus
    Posts
    55

    after run advanced filter, only shows headline or show al without filter

    Hi could you please advise why the macro for advanced filter is working, every time, I run macro, they only copy head into selected place, no content, thanks
    Attached Files Attached Files
    Last edited by reedzhou; 06-12-2014 at 11:15 PM. Reason: use wrong title

  2. #2
    Valued Forum Contributor
    Join Date
    09-21-2011
    Location
    Birmingham UK
    MS-Off Ver
    Excel 2003/7/10
    Posts
    2,188

    Re: macro not working

    Where are your criteria?

    Please Login or Register  to view this content.
    Hope this helps

    Sometimes its best to start at the beginning and learn VBA & Excel.

    Please dont ask me to do your work for you, I learnt from Reading books, Recording, F1 and Google and like having all of this knowledge in my head for the next time i wish to do it, or wish to tweak it.
    Available for remote consultancy work PM me

  3. #3
    Forum Expert Fotis1991's Avatar
    Join Date
    10-11-2011
    Location
    Athens(The homeland of the Democracy!). Greece
    MS-Off Ver
    Excel 1997!&2003 & 2007&2010
    Posts
    13,744

    Re: macro not working

    Your post does not comply with Rule 1 of our Forum RULES. Your post title should accurately and concisely describe your problem, not your anticipated solution.

    Use terms appropriate to a Google search. Poor thread titles, like Please Help, Urgent, Need Help, Formula Problem, Code Problem, and Need Advice will be addressed according to the OP's experience in the forum: If you have less than 10 posts, expect (and respond to) a request to change your thread title. If you have 10 or more posts, expect your post to be locked, so you can start a new thread with an appropriate title.

    To change a Title on your post, click EDIT then Go Advanced and change your title, if 2 days have passed ask a moderator to do it for you.

    (This thread should receive no further responses until this moderation request is fulfilled, as per Forum Rule 7)
    Regards

    Fotis.

    -This is my Greek whisper to Europe.

    --Remember, saying thanks only takes a second or two. Click the little star * below, to give some Rep if you think an answer deserves it.

    Advanced Excel Techniques: http://excelxor.com/

    --KISS(Keep it simple Stupid)

    --Bring them back.

    ---See about Acropolis of Athens.

    --Visit Greece.

  4. #4
    Registered User
    Join Date
    04-01-2009
    Location
    Australia
    MS-Off Ver
    Microsoft Professional 2010 plus
    Posts
    55

    Re: macro not working

    thanks, Nathansav

    please see below VBA. Could you please advise why it is not working, every time, only title turns up or the whole spreadsheet turn up.

    another question, can I put criteria on another sheet to run advanced filter? thank you in advance

    PHP Code: 
       Sheets("REPORT").Select
        Range
    ("A22:J460").Delete
        Sheets
        Sheets
    ("Details").Range("A12:J460").AdvancedFilter Action:=xlFilterCopy_
        CriteriaRange
    :=Range("A9:J10"), CopyToRange:=Sheets("REPORT").Range("A22"), Unique:=False
        Sheets
    ("REPORT").Select
        Range
    ("A3").Select
           
    End Sub 
    Attached Files Attached Files
    Last edited by reedzhou; 06-12-2014 at 10:54 PM. Reason: change code

  5. #5
    Forum Moderator alansidman's Avatar
    Join Date
    02-02-2010
    Location
    Steamboat Springs, CO
    MS-Off Ver
    MS Office 365 insider Version 2505 Win 11
    Posts
    24,754

    Re: macro not working

    Your post does not comply with Rule 7 of our Forum RULES. Please do not ignore requests by Administrators, Moderators and senior forum members regarding forum rules.

    If you are unclear about the request or instruction then send a private message to them asking for clarification. Do not post a reply in a thread where a moderator has requested an action that has not yet been complied with e.g Title change or Code tags...etc

    Also:

    Your post does not comply with Rule 3 of our Forum RULES. Use code tags around code.

    Posting code between [CODE]Please [url=https://www.excelforum.com/login.php]Login or Register [/url] to view this content.[/CODE] tags makes your code much easier to read and copy for testing, it also maintains VBA formatting.

    Highlight your code and click the # icon at the top of your post window. More information about these and other tags can be found here



    (This thread should receive no further responses until this moderation request is fulfilled, as per Forum Rule 7)
    Alan עַם יִשְׂרָאֵל חַי


    Change an Ugly Report with Power Query
    Database Normalization
    Complete Guide to Power Query
    Man's Mind Stretched to New Dimensions Never Returns to Its Original Form

  6. #6
    Forum Moderator alansidman's Avatar
    Join Date
    02-02-2010
    Location
    Steamboat Springs, CO
    MS-Off Ver
    MS Office 365 insider Version 2505 Win 11
    Posts
    24,754

    Re: after run advanced filter, only shows headline or show al without filter

    Which field should you be setting the criteria for? You can establish a variable for the criteria and it could be a range in a different worksheet. But until you set a criteria, your autofilter does not know what to filter.

    This link may help you.

    http://www.ozgrid.com/VBA/autofilter-vba-criteria.htm

  7. #7
    Forum Guru Izandol's Avatar
    Join Date
    03-29-2012
    Location
    *
    MS-Off Ver
    Excel 20(03|10|13)
    Posts
    2,581

    Re: after run advanced filter, only shows headline or show al without filter

    Please try:

    Please Login or Register  to view this content.
    • Please remember to mark threads Solved with Thread Tools link at top of page.
    • Please use code tags when posting code: [code]Place your code here[/code]
    • Please read Forum Rules

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Replies: 1
    Last Post: 05-27-2014, 02:40 PM
  2. Macro not working while running multiple others macro..
    By calvinle in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 03-07-2014, 11:27 AM
  3. [SOLVED] Macro to merge duplicate rows unique values - current macro not working
    By aimeecrystalaid in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 11-06-2013, 03:42 PM
  4. Macro not working in Excel 2010 but working in Excel 2003
    By mvel_sky in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 08-02-2013, 04:18 PM
  5. Converting workbook with Macro to a template causes the Macro to stop working
    By Skeeta in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 11-20-2012, 02:00 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1