PDA

View Full Version : I Need Help Vba Code Automatically Sort Rows Largest To Smallest



etheer
02-21-2014, 03:44 AM
Hi
I Need Help Vba Code Automatically Sort Rows Largest To Smallest IF Cell G > 50% And Cell D > 1%

etheer
02-21-2014, 07:59 AM
Please help me

etheer
02-21-2014, 11:06 AM
I need edit this code work automatically


Sub sort()
'
' sort Macro
Selection.sort Key1:=Range("N7"), Order1:=xlDescending, Header:=xlGuess, _
OrderCustom:=1, MatchCase:=False, Orientation:=xlTopToBottom, _
DataOption1:=xlSortNormal

End Sub

sassora
02-22-2014, 12:22 AM
What would the output look like based on your example? Where are the rows that don't match the criteria put?

etheer
02-22-2014, 01:28 AM
i want this code work automatically

Sub sort()
'
' sort Macro
Selection.sort Key1:=Range("N7"), Order1:=xlDescending, Header:=xlGuess, _
OrderCustom:=1, MatchCase:=False, Orientation:=xlTopToBottom, _
DataOption1:=xlSortNormal

End Sub

snb
02-22-2014, 05:18 AM
It's no use to post the same code twice.
Please use codetags if you post VBA-code & read the forum rules !

I get the impression your expectations do no match the function of a forum: the forum is not meant to provide free, easy solutions but is meant to help you to devise your own solutions. Basically you have to do the fundamental coding yourself. Don't post copied code (or unadapted recorded code) from elsewhere asking 'can you adopt it to my goal'.

etheer
02-22-2014, 09:37 AM
i am sorry snb

sassora
02-22-2014, 10:39 AM
If I wanted to be blunt, I would say that your code does enable to you sort descending values automatically. Can you please assume we aren't stupid and think about the information we might need to help you. Snb is right, you should at least have a willingness to learn, I don't think that this is the case here.

I'm not keen to further reply to this thread.