is this possible with vba ?

Peter1973

Well-known Member
Joined
May 13, 2006
Messages
955
I have no idead how to do this even if it's possible in excel.

I have spread sheet with various info in one sheet ( stats ) has a table which is derived from other data. One of the main factors in this data is the times enterered in sheet ( mater input sheet ) cells D1:D1000 in hh:mm format.

I am trying to find a macro to run which will a change the times in the master input sheet D1:D1000 to other times ( need this to be random times in 15 min increments ie 11:00, 14:15, 21:45 etc )

Any help appreciated

I would like the sheet to then look at the table in sheet stats cells A1:h100 which will have numer both +ve and -ve and keep entering times in the master input sheet D1:D1000 untill it finds the ones that give hte best reult in the table in the sheet stats ( best result is all number or as many as possible are +ve ) but I know I am dreaming to get the sheet to do this so the first question will do me.
 

Excel Facts

Whats the difference between CONCAT and CONCATENATE?
The newer CONCAT function can reference a range of cells. =CONCATENATE(A1,A2,A3,A4,A5) becomes =CONCAT(A1:A5)
Not quite sure what you're going for here, but the following formula will generate random times in 15 minute increments, if that's any use

=INT(RAND()*96)/96

You should format the cell to time hh:mm to see the results
 
Upvote 0
I have thought about this and think it is a job for a mathematical genius, as what im trying to get it for the cells D1:D1000 to go through every possible combination of time in 15 min increments so i can see the reults in stats table to see which is the best combination. I know im expecting the world from my lowly pc
 
Upvote 0
If you have a time in A1(Say 1:00), then
Code:
=A1+1/24/4
copied down will increment by 15 minute intervals. Custom format cells as either hh:mm or [hh]:mm

lenze
 
Upvote 0
Its ok as the cells i need to change constantly to utilise every possible combimation of time from 00:00 to 23:45 and give me the one which produces the best reult in the stat table ( there will be millions of combinations ) Thanks for all your help but think this is beyond excels capability
 
Upvote 0

Forum statistics

Threads
1,213,526
Messages
6,114,122
Members
448,550
Latest member
CAT RG

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top