Hi,
Want to create a macro based on column "N" at column at column "AR",I have created the below code but its taking reference to some other column,pl advice.
Please Login or Register to view this content.
Hi,
Want to create a macro based on column "N" at column at column "AR",I have created the below code but its taking reference to some other column,pl advice.
Please Login or Register to view this content.
Last edited by arnab0711; 01-25-2011 at 05:27 AM.
Hi aranab0711
Two problems from the above code. You have no data in column AR so it will come back as 1 in the following line.I believe you want to change all of you "AR"'s in the code above ot "N".Please Login or Register to view this content.
See if that works for you data.
One test is worth a thousand opinions.
Click the * Add Reputation below to say thanks.
Well,the above code is not working,the logic will be some what like thisBut I want to create a macro for this formula.=IF(n2<=30,"0<30",IF(n2<=60,"30-60",if(n2<90,"60-90",if(n2<180,"90-180",">180"))))
Hi,
Not working is a little vague. What are your expected results?
The macro will do somewhat like this -
1)The macro will lookup for a number in column "N"
2)In result will be in column "AR"
3)The logic will be if the number is >180 it will ">180"
if the # is >90 it will show "90 - 180"
if the # is >60 it will show "60-90"
if the # is >30 it will show "30-60"
if the # is <30 it will show "<30"
Try this;
Look at http://www.cpearson.com/excel/Debug.htm and use BreakPoints and Stepping. This section will help you do these with ease in the future.Please Login or Register to view this content.
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks