Specifying range in VBA macrosHow to get the starting and ending rownum when using EXCEL Autofilter function in VBAHow to avoid using Select in Excel VBAAutofilter in VBA with criteria as a range of cells'No Cells' After applying autofilter: Excel VBAExcel Macro for multiple filterCopy AutoFiltered Data Loop Until EndSelecting a Range in filtered data - Excel VBAEXCEL VBA Not exact match auto filterFiltering a macro with several valuesVBA Excel | Filter multuple columns based on single value
Who was the lone kid in the line of people at the lake at the end of Avengers: Endgame?
How to prevent z-fighting in OpenSCAD?
Why does nature favour the Laplacian?
Betweenness centrality formula
Minor Revision with suggestion of an alternative proof by reviewer
How to denote matrix elements succinctly?
Implications of cigar-shaped bodies having rings?
What is the smallest unit of eos?
Check if a string is entirely made of the same substring
Apply MapThread to all but one variable
Can SQL Server create collisions in system generated constraint names?
Was there a Viking Exchange as well as a Columbian one?
What term is being referred to with "reflected-sound-of-underground-spirits"?
Why was the Spitfire's elliptical wing almost uncopied by other aircraft of World War 2?
Is Diceware more secure than a long passphrase?
On The Origin of Dissonant Chords
What are the steps to solving this definite integral?
Do I have an "anti-research" personality?
Converting a sprinkler system's 24V AC outputs to 3.3V DC logic inputs
Don’t seats that recline flat defeat the purpose of having seatbelts?
How can Republicans who favour free markets, consistently express anger when they don't like the outcome of that choice?
Could the terminal length of components like resistors be reduced?
How to display Aura JS Errors Lightning Out
What is the most expensive material in the world that could be used to create Pun-Pun's lute?
Specifying range in VBA macros
How to get the starting and ending rownum when using EXCEL Autofilter function in VBAHow to avoid using Select in Excel VBAAutofilter in VBA with criteria as a range of cells'No Cells' After applying autofilter: Excel VBAExcel Macro for multiple filterCopy AutoFiltered Data Loop Until EndSelecting a Range in filtered data - Excel VBAEXCEL VBA Not exact match auto filterFiltering a macro with several valuesVBA Excel | Filter multuple columns based on single value
.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty height:90px;width:728px;box-sizing:border-box;
I am really new to VBA. SO this might seem a silly question for experts.
after researching the internet on how to put dynamic range for filters in excel considering a situation when your list might grow or shrink I stumbled on couple of ways. One of them is as the following.
ActiveSheet.Range("A1").AutoFilter Field:=46, Criteria1:="1"
I know the you can put two arguments to specify ranges and the second one is optional. In this particular I am just putting the first cell where my data starts. My questions are below:
- does the code automatically select the active range based on the first specified cell?
- Had my data started from "C5" would i still have to chose the argument as "A1"?
- I am filtering out something from column 46. what does it matter where I specify my first cell? for example if I had chosen "C5" instead of "A1" how it would have affected my macro?
- Let's say, I want to filter out something from column 2 ie, Field 2. But the argument for range I choose as "D5". How it would affect my macro code?
excel vba
add a comment |
I am really new to VBA. SO this might seem a silly question for experts.
after researching the internet on how to put dynamic range for filters in excel considering a situation when your list might grow or shrink I stumbled on couple of ways. One of them is as the following.
ActiveSheet.Range("A1").AutoFilter Field:=46, Criteria1:="1"
I know the you can put two arguments to specify ranges and the second one is optional. In this particular I am just putting the first cell where my data starts. My questions are below:
- does the code automatically select the active range based on the first specified cell?
- Had my data started from "C5" would i still have to chose the argument as "A1"?
- I am filtering out something from column 46. what does it matter where I specify my first cell? for example if I had chosen "C5" instead of "A1" how it would have affected my macro?
- Let's say, I want to filter out something from column 2 ie, Field 2. But the argument for range I choose as "D5". How it would affect my macro code?
excel vba
2
My answer is to find out for yourself! Testing this yourself will allow you to actually see what happens when you tweak the available options available to you from theRange.Autofilter
method. While we could show you, doing it yourself is a great learning exp and you are much more likely to remember the results after seeing them.
– urdearboy
Mar 22 at 18:04
add a comment |
I am really new to VBA. SO this might seem a silly question for experts.
after researching the internet on how to put dynamic range for filters in excel considering a situation when your list might grow or shrink I stumbled on couple of ways. One of them is as the following.
ActiveSheet.Range("A1").AutoFilter Field:=46, Criteria1:="1"
I know the you can put two arguments to specify ranges and the second one is optional. In this particular I am just putting the first cell where my data starts. My questions are below:
- does the code automatically select the active range based on the first specified cell?
- Had my data started from "C5" would i still have to chose the argument as "A1"?
- I am filtering out something from column 46. what does it matter where I specify my first cell? for example if I had chosen "C5" instead of "A1" how it would have affected my macro?
- Let's say, I want to filter out something from column 2 ie, Field 2. But the argument for range I choose as "D5". How it would affect my macro code?
excel vba
I am really new to VBA. SO this might seem a silly question for experts.
after researching the internet on how to put dynamic range for filters in excel considering a situation when your list might grow or shrink I stumbled on couple of ways. One of them is as the following.
ActiveSheet.Range("A1").AutoFilter Field:=46, Criteria1:="1"
I know the you can put two arguments to specify ranges and the second one is optional. In this particular I am just putting the first cell where my data starts. My questions are below:
- does the code automatically select the active range based on the first specified cell?
- Had my data started from "C5" would i still have to chose the argument as "A1"?
- I am filtering out something from column 46. what does it matter where I specify my first cell? for example if I had chosen "C5" instead of "A1" how it would have affected my macro?
- Let's say, I want to filter out something from column 2 ie, Field 2. But the argument for range I choose as "D5". How it would affect my macro code?
excel vba
excel vba
asked Mar 22 at 17:25
sbash005sbash005
6
6
2
My answer is to find out for yourself! Testing this yourself will allow you to actually see what happens when you tweak the available options available to you from theRange.Autofilter
method. While we could show you, doing it yourself is a great learning exp and you are much more likely to remember the results after seeing them.
– urdearboy
Mar 22 at 18:04
add a comment |
2
My answer is to find out for yourself! Testing this yourself will allow you to actually see what happens when you tweak the available options available to you from theRange.Autofilter
method. While we could show you, doing it yourself is a great learning exp and you are much more likely to remember the results after seeing them.
– urdearboy
Mar 22 at 18:04
2
2
My answer is to find out for yourself! Testing this yourself will allow you to actually see what happens when you tweak the available options available to you from the
Range.Autofilter
method. While we could show you, doing it yourself is a great learning exp and you are much more likely to remember the results after seeing them.– urdearboy
Mar 22 at 18:04
My answer is to find out for yourself! Testing this yourself will allow you to actually see what happens when you tweak the available options available to you from the
Range.Autofilter
method. While we could show you, doing it yourself is a great learning exp and you are much more likely to remember the results after seeing them.– urdearboy
Mar 22 at 18:04
add a comment |
1 Answer
1
active
oldest
votes
AutoFilter: A Small Study
- Well, I was curious, too. So I studied it a little bit and created a
workbook where you can input the parameters of some of the arguments
of theAutoFilter
method and just by clicking on a command button
apply the changes. The next click removes the filter. - The workbook also contains the results of the behavior when changing
by row. The same thing could be done by column.
Workbook
Download
(Dropbox)
The following image displays the initial state of the only worksheet in the workbook.
This I was most curious about: what would happen if I would filter in C8
. There's a surprise.
There still remains a ton of unanswered questions, but this could get you started to investigate deeper.
add a comment |
Your Answer
StackExchange.ifUsing("editor", function ()
StackExchange.using("externalEditor", function ()
StackExchange.using("snippets", function ()
StackExchange.snippets.init();
);
);
, "code-snippets");
StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "1"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);
else
createEditor();
);
function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader:
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
,
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);
);
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55304876%2fspecifying-range-in-vba-macros%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
AutoFilter: A Small Study
- Well, I was curious, too. So I studied it a little bit and created a
workbook where you can input the parameters of some of the arguments
of theAutoFilter
method and just by clicking on a command button
apply the changes. The next click removes the filter. - The workbook also contains the results of the behavior when changing
by row. The same thing could be done by column.
Workbook
Download
(Dropbox)
The following image displays the initial state of the only worksheet in the workbook.
This I was most curious about: what would happen if I would filter in C8
. There's a surprise.
There still remains a ton of unanswered questions, but this could get you started to investigate deeper.
add a comment |
AutoFilter: A Small Study
- Well, I was curious, too. So I studied it a little bit and created a
workbook where you can input the parameters of some of the arguments
of theAutoFilter
method and just by clicking on a command button
apply the changes. The next click removes the filter. - The workbook also contains the results of the behavior when changing
by row. The same thing could be done by column.
Workbook
Download
(Dropbox)
The following image displays the initial state of the only worksheet in the workbook.
This I was most curious about: what would happen if I would filter in C8
. There's a surprise.
There still remains a ton of unanswered questions, but this could get you started to investigate deeper.
add a comment |
AutoFilter: A Small Study
- Well, I was curious, too. So I studied it a little bit and created a
workbook where you can input the parameters of some of the arguments
of theAutoFilter
method and just by clicking on a command button
apply the changes. The next click removes the filter. - The workbook also contains the results of the behavior when changing
by row. The same thing could be done by column.
Workbook
Download
(Dropbox)
The following image displays the initial state of the only worksheet in the workbook.
This I was most curious about: what would happen if I would filter in C8
. There's a surprise.
There still remains a ton of unanswered questions, but this could get you started to investigate deeper.
AutoFilter: A Small Study
- Well, I was curious, too. So I studied it a little bit and created a
workbook where you can input the parameters of some of the arguments
of theAutoFilter
method and just by clicking on a command button
apply the changes. The next click removes the filter. - The workbook also contains the results of the behavior when changing
by row. The same thing could be done by column.
Workbook
Download
(Dropbox)
The following image displays the initial state of the only worksheet in the workbook.
This I was most curious about: what would happen if I would filter in C8
. There's a surprise.
There still remains a ton of unanswered questions, but this could get you started to investigate deeper.
answered Mar 22 at 20:16
VBasic2008VBasic2008
3,5372517
3,5372517
add a comment |
add a comment |
Thanks for contributing an answer to Stack Overflow!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55304876%2fspecifying-range-in-vba-macros%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
2
My answer is to find out for yourself! Testing this yourself will allow you to actually see what happens when you tweak the available options available to you from the
Range.Autofilter
method. While we could show you, doing it yourself is a great learning exp and you are much more likely to remember the results after seeing them.– urdearboy
Mar 22 at 18:04