NANCY SKYES
New Member
- Joined
- Aug 12, 2019
- Messages
- 13
Hello
This my first post so I hope this is clear.
I was looking for help to develop a macro that searches a large number of different ranges for values 26 and higher and to write the cell location results to cells B3, B4, B5 or B6. Some ranges may or may not have sets of numbers in them. I’m only interested in sets of numbers that have a value of 26 (2nd number in a set of numbers) or higher in them. An example would be 8-26 or 7-35. there will always be data in some of the cell ranges. Please see my sample data below with expected result.
- I can not use a formula because their are issues with some other VBA code I run in the same cell range.
- I need hard code for the search ranges (I have many ranges in different locations on the sheet) so I can add or delete in the code as required. There is data above the cell ranges almost always.
- The sheet name is Sheet 1 and their is only one sheet in the workbook.
- Using Excel 2007.
- The search range cells are formatted as text.
- The write cells are formatted as general.
Sample data:
The code searches ranges D3:D100, F30:F120, H1:H122. The first found set of numbers would be
10-26 in cell D9 and the 2nd positive set of numbers would be 5-35 located in cell F40. The code would then write the cell location to cells B3, B4, B5 or B6. If their are NO positive results could the code write a 0 in cell B3 when finished.
If you have any questions please ask so I can clarify any issue(s).
Thanks so much for all your help.
[h=2][/h] <style type="text/css">h2 { direction: ltr; color: rgb(0, 0, 0); text-align: left; }h2.western { font-family: "Liberation Serif", sans-serif; }h2.cjk { font-family: "WenQuanYi Micro Hei"; }h2.ctl { font-family: "Lohit Devanagari"; }p { margin-bottom: 0.25cm; direction: ltr; color: rgb(0, 0, 0); line-height: 115%; text-align: left; }p.western { font-family: "Liberation Serif", serif; font-size: 12pt; }p.cjk { font-family: "WenQuanYi Micro Hei"; font-size: 12pt; }p.ctl { font-family: "Lohit Devanagari"; font-size: 12pt; }a:link { }</style>
This my first post so I hope this is clear.
I was looking for help to develop a macro that searches a large number of different ranges for values 26 and higher and to write the cell location results to cells B3, B4, B5 or B6. Some ranges may or may not have sets of numbers in them. I’m only interested in sets of numbers that have a value of 26 (2nd number in a set of numbers) or higher in them. An example would be 8-26 or 7-35. there will always be data in some of the cell ranges. Please see my sample data below with expected result.
- I can not use a formula because their are issues with some other VBA code I run in the same cell range.
- I need hard code for the search ranges (I have many ranges in different locations on the sheet) so I can add or delete in the code as required. There is data above the cell ranges almost always.
- The sheet name is Sheet 1 and their is only one sheet in the workbook.
- Using Excel 2007.
- The search range cells are formatted as text.
- The write cells are formatted as general.
Sample data:
The code searches ranges D3:D100, F30:F120, H1:H122. The first found set of numbers would be
10-26 in cell D9 and the 2nd positive set of numbers would be 5-35 located in cell F40. The code would then write the cell location to cells B3, B4, B5 or B6. If their are NO positive results could the code write a 0 in cell B3 when finished.
If you have any questions please ask so I can clarify any issue(s).
Thanks so much for all your help.
[h=2][/h] <style type="text/css">h2 { direction: ltr; color: rgb(0, 0, 0); text-align: left; }h2.western { font-family: "Liberation Serif", sans-serif; }h2.cjk { font-family: "WenQuanYi Micro Hei"; }h2.ctl { font-family: "Lohit Devanagari"; }p { margin-bottom: 0.25cm; direction: ltr; color: rgb(0, 0, 0); line-height: 115%; text-align: left; }p.western { font-family: "Liberation Serif", serif; font-size: 12pt; }p.cjk { font-family: "WenQuanYi Micro Hei"; font-size: 12pt; }p.ctl { font-family: "Lohit Devanagari"; font-size: 12pt; }a:link { }</style>