Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Do you manage to make this macro faster??
This marco take over 1 min to run for me....
Does anybody have clue if i can get the run time down. Br Petter Sheets("Sheet2").Select For i = 0 To 92 rownr = 105 - i Fjern = Cells(rownr, 6).Value If Fjern = "Order backlog" Or Fjern = "Orders received" Then Else: Range("e" & rownr & ",g" & rownr & ",k" & rownr & ":m" & rownr).ClearContents End If Next i |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Do you manage to make this macro faster??
A lot would depend on what the macro does after the THEN statement. The one
you posted below goes straight to an ELSE statement. Post the correct macro. Mike "Fingerjob" wrote: This marco take over 1 min to run for me.... Does anybody have clue if i can get the run time down. Br Petter Sheets("Sheet2").Select For i = 0 To 92 rownr = 105 - i Fjern = Cells(rownr, 6).Value If Fjern = "Order backlog" Or Fjern = "Orders received" Then Else: Range("e" & rownr & ",g" & rownr & ",k" & rownr & ":m" & rownr).ClearContents End If Next i |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Do you manage to make this macro faster??
Hi
This is the whole macro. There should not be anything after the THEN statement since i dont want the macro do anything if the IF statment is true. I just want the macro to do something if the Statment is NOT true ( else: statmentet) Br Petter Mike H skrev: A lot would depend on what the macro does after the THEN statement. The one you posted below goes straight to an ELSE statement. Post the correct macro. Mike "Fingerjob" wrote: This marco take over 1 min to run for me.... Does anybody have clue if i can get the run time down. Br Petter Sheets("Sheet2").Select For i = 0 To 92 rownr = 105 - i Fjern = Cells(rownr, 6).Value If Fjern = "Order backlog" Or Fjern = "Orders received" Then Else: Range("e" & rownr & ",g" & rownr & ",k" & rownr & ":m" & rownr).ClearContents End If Next i |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
Do you manage to make this macro faster??
Maybe turning calculation to manual
then your code then back to automatic (or whatever it was before) would speed things up. Fingerjob wrote: This marco take over 1 min to run for me.... Does anybody have clue if i can get the run time down. Br Petter Sheets("Sheet2").Select For i = 0 To 92 rownr = 105 - i Fjern = Cells(rownr, 6).Value If Fjern = "Order backlog" Or Fjern = "Orders received" Then Else: Range("e" & rownr & ",g" & rownr & ",k" & rownr & ":m" & rownr).ClearContents End If Next i -- Dave Peterson |
#5
Posted to microsoft.public.excel.programming
|
|||
|
|||
Do you manage to make this macro faster??
Not sure if it will speed up your macro, but if you want to know if something
is not equal, you may want to use "<" instead of "=" "Dave Peterson" wrote: Maybe turning calculation to manual then your code then back to automatic (or whatever it was before) would speed things up. Fingerjob wrote: This marco take over 1 min to run for me.... Does anybody have clue if i can get the run time down. Br Petter Sheets("Sheet2").Select For i = 0 To 92 rownr = 105 - i Fjern = Cells(rownr, 6).Value If Fjern = "Order backlog" Or Fjern = "Orders received" Then Else: Range("e" & rownr & ",g" & rownr & ",k" & rownr & ":m" & rownr).ClearContents End If Next i -- Dave Peterson |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
How can make Save faster | Excel Programming | |||
can you make this faster? | Excel Programming | |||
How Can I make excel go faster | Excel Programming | |||
make my vba/excel program faster | Excel Programming | |||
make my VBA program faster | Excel Programming |