Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.misc
|
|||
|
|||
VBA - Need macro to find optimal placement of rows in pairs
Hi
I could use some help in programming a macro that calculates the optimal placement of elements. I have 50 rows with data. Coloumn B has numbers ranging from 1500-8600. I need a macro that can lookup the coloum with the highest number and find another row with the highest number which when added can be no higher than 8600 and copy these two coloumn to another placement. Eg. 7.500 mm 7.000 mm 6.800 mm 6.000 mm 5.400 mm 5.400 mm 5.200 mm 3.600 mm 3.600 mm 3.500 mm 2.500 mm 2.400 mm 1.000 mm It should now take the coloumn with 7.500 mm and see that combined with the coloumn with 1.000 mm it gives no more than 8600 mm and copy/ cut these two out of the table and then control the next coloumn(7.000 mm) and find if anything goes with together with this still under 8600 mm but as close to ass possible. Does this make any sense? Hope I haven't confused you too much. Any help, advise etc. will be welcome... Greetings Kasper |
#2
Posted to microsoft.public.excel.misc
|
|||
|
|||
VBA - Need macro to find optimal placement of rows in pairs
On 10 Dec., 15:47, Kasper wrote:
Hi I could use some help in programming a macro that calculates the optimal placement of elements. I have 50 rows with data. Coloumn B has numbers ranging from 1500-8600. I need a macro that can lookup the coloum with the highest number and find another row with the highest number which when added can be no higher than 8600 and copy these two coloumn to another placement. Eg. 7.500 mm 7.000 mm 6.800 mm 6.000 mm 5.400 mm 5.400 mm 5.200 mm 3.600 mm 3.600 mm 3.500 mm 2.500 mm 2.400 mm 1.000 mm It should now take the coloumn with 7.500 mm and see that combined with the coloumn with 1.000 mm it gives no more than 8600 mm and copy/ cut these two out of the table and then control the next coloumn(7.000 mm) and find if anything goes with together with this still under 8600 mm but as close to ass possible. Does this make any sense? Hope I haven't confused you too much. Any help, advise etc. will be welcome... Greetings Kasper No ideas? |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Macro to pull data with criterea for placement on a new sheet | Excel Discussion (Misc queries) | |||
Cursor placement without Macro/VBA | New Users to Excel | |||
Sorting rows by pairs | Excel Worksheet Functions | |||
Macro to find and delete rows! | Excel Discussion (Misc queries) | |||
Counting Match Pairs In Rows | Excel Worksheet Functions |