imrags has asked for the wisdom of the Perl Monks concerning the following question:
Here is what I do with my Perl code for it (snippet)Columns("M:N").Select Selection.Sort Key1:=Range("M2"), Order1:=xlAscending, Header:=xlY +es, _ OrderCustom:=1, MatchCase:=False, Orientation:=xlTopToBottom, +_ DataOption1:=xlSortNormal
However, this does not sort only columns M & N but the whole sheet... What am I missing?$Range_new1 = $Sheet->Range("m2"); $Range_new2 = $Sheet->Range("n2"); $Excel->Selection->Sort({Key1 => $Range_new1, Order1 => xlAscending, Key2 => $Range_new2, Header=>xlYes, OrderCustom=>1, MatchCase => False, DataOption1 => xlSortNormal});
$Range_new1 = $Sheet->Range("m:n"); $Range_new2 = $Sheet->Range("n2"); $Excel->Selection->Sort({Key1 => $Range_new1, Order1 => xlAscending, #Key2 => $Range_new2, Header=>xlYes, OrderCustom=>1, MatchCase => False, DataOption1 => xlSortNormal});
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Win32::OLE Excel question
by 1Nf3 (Pilgrim) on Jan 05, 2009 at 09:44 UTC | |
|
Re: Win32::OLE Excel question
by Corion (Patriarch) on Jan 05, 2009 at 08:45 UTC | |
by imrags (Monk) on Jan 05, 2009 at 09:14 UTC | |
by Corion (Patriarch) on Jan 05, 2009 at 09:32 UTC | |
|
Re: Win32::OLE Excel question
by imrags (Monk) on Jan 05, 2009 at 09:48 UTC | |
by subbu_avd (Initiate) on Jan 20, 2009 at 11:35 UTC | |
|
Re: Win32::OLE Excel question
by Anonymous Monk on Jan 05, 2009 at 07:17 UTC |