0
Rebecca

Seriously-Damsel In Distress-need Visual Basic help!

Recommended Posts

Hi guys,

It's been awhile, and I was never much for coding in the first place. But I know this shouldn't take much for some one who knows their stuff.

I'm in Excel, with about 160 columns to sort individually. Don't want to manually of course. How do I write the macro to loop, sorting one column's range after the one to the left and so on? I've got the sort command and ranges covered, just don't know how to loop.

Anyone who knows can feel fre to PM, or keep it here, in case others give a crap.

you've got to ask yourself one question: 'Do I feel loquacious?' -- well do you, punk?

Share this post


Link to post
Share on other sites
Quote

I've not messed around with VB much...but I'm looking for a solution for ya!



You're an angel! I'm looking too, just so y'all know I'm trying to rescue myself while the cavalry's on the way. I'll let you know if I figure it out!

Thanks!:)

you've got to ask yourself one question: 'Do I feel loquacious?' -- well do you, punk?

Share this post


Link to post
Share on other sites
Well, what you can do is to RECORD a new macro:

Tools -> Macro -> Record New Macro

So, you select the rows, columns, etc, then go DATA and click on SORT, save the macro and VOILA!!!
__________________________________________
Blue Skies and May the Force be with you.

Share this post


Link to post
Share on other sites
Wahoo! I got it! Thanks Wildblue and the rest of y'all!

Slappie, nice try dude! :ph34r:

Here it is if anyone needs anything similar:

Dim col As Range
Range("Your Range Here").Select
For Each col In Selection.Columns
Intersect(col, Selection, ActiveSheet.UsedRange). _
Sort Key1:=col, Order1:=xlDescending, Header:=xlGuess, _
OrderCustom:=1, MatchCase:=False, Orientation:=xlTopToBottom
Next

you've got to ask yourself one question: 'Do I feel loquacious?' -- well do you, punk?

Share this post


Link to post
Share on other sites
Quote

Wahoo! I got it! Thanks Wildblue and the rest of y'all!

Slappie, nice try dude!



*Stomps around in a fit of frustration!* GDI!! It was a valiant attempt! You have to admit I almost got you to post us some boobage pics! :)



"Find out just what any people will quietly submit to and you have found out the exact measure of injustice and wrong which will be imposed upon them."

Share this post


Link to post
Share on other sites
BWAHAHAHAHA!!

Yeah, times ain't what they used to be. We're wearing shoes, not breeding, making reservations for dinner, and voting too. Get out now, it's all downhill from here! :D

Uppity bitches...


:ph34r:

edit: Dammit, I want a nice sammich, too! Hey Slappie! Go make me and Bill some sammiches! [Stewie] And no onions! God help you if I find onion! [/Stewie]

you've got to ask yourself one question: 'Do I feel loquacious?' -- well do you, punk?

Share this post


Link to post
Share on other sites
Quote

I knew something was up when Kerry was spending $300 on a hairdo. If it was only men voting, he'd be down at Clip-and-Save spending four-fittee like the rest of us.


But, but lustrous hair and expensive grooming are essential traits of a good leader! As well as how good-looking and athletic he is!

Nah, if it was ONLY men voting, they'd just whip 'em out, measure 'em, weigh the boys, and go with the winner. :ph34r:

Quote

If they had a real man to love 'em, they'd be happier doing that than voting. :)

Luckily, voting only took about 30 minutes out of my life this year, just long enough for him to start the laundry and fix me a sammich before I got back home. >:(

you've got to ask yourself one question: 'Do I feel loquacious?' -- well do you, punk?

Share this post


Link to post
Share on other sites
[QUOTE]Luckily, voting only took about 30 minutes out of my life this year, just long enough for him to start the laundry and fix me a sammich before I got back home.[/QUOTE]

[B]ZIIINNNNGGGGGGGGGGGG!! OUCH!![/B]



"Find out just what any people will quietly submit to and you have found out the exact measure of injustice and wrong which will be imposed upon them."

Share this post


Link to post
Share on other sites
Quote

Nah, if it was ONLY men voting, they'd just whip 'em out, measure 'em, weigh the boys, and go with the winner.



Simplifying the process to the essentials would make more sense. We'd get the same quality in elected officials too. ;)

Of course, I'm thinking that women would be watching more political debates. :)


Quote

Luckily, voting only took about 30 minutes out of my life this year, just long enough for him to start the laundry and fix me a sammich before I got back home.



Dayum... you must be spending more time on the lovin' than you did voting if he's doing that. I promise that if you support me well, I will stay home and do most of the laundry. :) :)

Share this post


Link to post
Share on other sites
Quote

Of course, I'm thinking that women would be watching more political debates. :)



Ron Jeremy for President!!!


Quote

Dayum... you must be spending more time on the lovin' than you did voting if he's doing that. I promise that if you support me well, I will stay home and do most of the laundry. :) :)



:) Tee hee! Well, I DO keep my man happy....
Just kidding though - we share the housework.
He messes it up, and I hire a housekeeper.
Works out beautifully. ;)

(If you read this honey, I'm just playin'! B|)

you've got to ask yourself one question: 'Do I feel loquacious?' -- well do you, punk?

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

0