Excel - Como ordenar por filas en excel

 
Vista:

Como ordenar por filas en excel

Publicado por Juan379 (2 intervenciones) el 14/01/2008 21:37:10
Hola que tal.

LO QUE PASA ES QUE EL EXCEL TIENE LA OPCION ORDENAR POR COLUMNAS Y POR FILAS PERO CON SOLO TRES CRITERIOS, LO QUE YO NECESITO ES ORDENAR UNAS 46560 FILAS DE 5 COLUMNAS POR EJEMPLO UNA DE LAS FILAS QUE TENGA LOS DATOS ASI 4 2 6 1 7 ORDENADOS TIENEN QUE QUEDAR DE LA SIGUIENTE MANERA 1 2 4 6 7 Y ESA MISMA OPERACION HACERLA EN TODAS LAS FILAS.

No se si realice esto con un macro o hay alguna opcion que se me paso ver pero desearia me que ayudaran en ello.
Valora esta pregunta
Me gusta: Está pregunta es útil y esta claraNo me gusta: Está pregunta no esta clara o no es útil
0
Responder

RE:Como ordenar por filas en excel

Publicado por Marvin Osorio (368 intervenciones) el 14/01/2008 21:45:04
Instala Office 2007 trae mas condiciones.

Salu2
Valora esta respuesta
Me gusta: Está respuesta es útil y esta claraNo me gusta: Está respuesta no esta clara o no es útil
0
Comentar

RE:Como ordenar por filas en excel

Publicado por Juan379 (2 intervenciones) el 14/01/2008 21:49:04
bueno lo que pasa es que excel no es mi fuerte y necesito una ayuda con referencia a ordenar esa hoja de cálculo, si lo hago uno por uno me llevara mucho tiempo ademas son 35 archivos que estan en la misma condicion y tengo que hacer la misma operacion en todos, por eso quiero saber una manera practica y rápida para porder hacerlo.

Gracias.
Valora esta respuesta
Me gusta: Está respuesta es útil y esta claraNo me gusta: Está respuesta no esta clara o no es útil
0
Comentar

RE:Como ordenar por filas en excel

Publicado por JuanC (792 intervenciones) el 15/01/2008 12:55:32
te dejo un código que puede ayudarte... si es que sabés qué hacer con él!!

Option Explicit
Option Base 1

'//By JuanC - Oct. 2007

Sub Ordenar_filas_Ex()
Dim Mx As Variant, v() As Variant
Dim i&, j&, m&, n&
Dim rng As Range
Set rng = [A1:J10]
With rng
m = .Rows.Count
n = .Columns.Count
Mx = .Value
End With
ReDim v(n) As Variant
For i = 1 To m
For j = 1 To n
v(j) = Mx(i, j)
Next
QuickSort v(), 1, n
For j = 1 To n
Mx(i, j) = v(j)
Next
Next
rng.Value = Mx
If IsArray(Mx) Then Erase Mx
Erase v
Set rng = Nothing
End Sub

Public Sub QuickSort(ByRef aV() As Variant, ByVal lFirst As Long, ByVal lLast As Long, Optional iDirection As Integer = 0)
Dim lLow&, lHigh&
Dim Sep As Variant, tmp As Variant
lLow = lFirst
lHigh = lLast
Sep = aV((lFirst + lLast) / 2)
Do
If iDirection = 0 Then
Do While (aV(lLow) < Sep)
lLow = lLow + 1
Loop
Do While (aV(lHigh) > Sep)
lHigh = lHigh - 1
Loop
Else
Do While (aV(lLow) > Sep)
lLow = lLow + 1
Loop
Do While (aV(lHigh) < Sep)
lHigh = lHigh - 1
Loop
End If
If (lLow <= lHigh) Then
tmp = aV(lLow)
aV(lLow) = aV(lHigh)
aV(lHigh) = tmp
lLow = lLow + 1
lHigh = lHigh - 1
End If
Loop While (lLow <= lHigh)
If (lFirst < lHigh) Then QuickSort aV, lFirst, lHigh, iDirection
If (lLow < lLast) Then QuickSort aV, lLow, lLast, iDirection
End Sub

Saludos desde Baires, JuanC
Valora esta respuesta
Me gusta: Está respuesta es útil y esta claraNo me gusta: Está respuesta no esta clara o no es útil
0
Comentar

RE:Como ordenar por filas en excel

Publicado por Jose Luis (1 intervención) el 04/05/2012 10:53:54
funciona perfecta, pero ¿para que no tenga en cuanta las que estan en blanco?
Valora esta respuesta
Me gusta: Está respuesta es útil y esta claraNo me gusta: Está respuesta no esta clara o no es útil
0
Comentar