+ Reply to Thread
Results 1 to 3 of 3

Countif using VBA to define range, criteria and result cell

  1. #1
    Registered User
    Join Date
    09-03-2012
    Location
    toronto,canada
    MS-Off Ver
    Excel 2003
    Posts
    2

    Countif using VBA to define range, criteria and result cell

    Hi I would like to create a code to link to a button. I am working with survey report data and would like to copy the "count" of each response type on a different worksheet. As each type of question may differ, the way that I organize the count may be different. What I would like to do is press a button, have an inputbox open, select range;then, select criteria; then, select the cell for the count.

    I have been reading this site but don't post often. If I make an error, I apologize. I am and trying to get the hang of this......

    Here is the code that I have entered.....

    countresponse Macro
    'create range for selecting the countif function

    Please Login or Register  to view this content.

    Any and all help deeply appreciated......trying to learn.

  2. #2
    Forum Expert mrice's Avatar
    Join Date
    06-22-2004
    Location
    Surrey, England
    MS-Off Ver
    Excel 2013
    Posts
    4,967

    Re: Countif using VBA to define range, criteria and result cell

    Try

    Please Login or Register  to view this content.
    Martin

  3. #3
    Registered User
    Join Date
    09-03-2012
    Location
    toronto,canada
    MS-Off Ver
    Excel 2003
    Posts
    2

    Re: Countif using VBA to define range, criteria and result cell

    Wow...thanks!

    I tried it and it works very well but only if I select the range on the same worksheet as the button. I will try to figure it out or repost.

    thank you!!!!

+ 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: 8
    Last Post: 08-02-2013, 05:13 AM
  2. [SOLVED] Need to properly dimension and define variable range for use in CountIf
    By under00c in forum Excel Programming / VBA / Macros
    Replies: 14
    Last Post: 06-08-2013, 09:52 AM
  3. [SOLVED] COUNTIF Criteria Does Not Return Expected Result
    By SLJackson in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 05-30-2013, 04:12 PM
  4. Define range to select from current cell in a full range (using worksheet_change)
    By draddy in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 01-07-2013, 11:48 AM
  5. Define named range where user can define size
    By nahousto in forum Excel General
    Replies: 4
    Last Post: 07-06-2009, 05:09 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