Macro to scroll table

RumMajor

New Member
Joined
Jul 16, 2012
Messages
11
Below I have added a table just to give you an idea of what I'm talking about. OK. So I am trying to make a table for my homework assignments that will allow me to put what the assignment is, what class it is for, and when it is due. For looks, and space reasons because of other things on the sheet. Is is divided into three columns basically (as you can see from the groups of numbers and headings)

AssignementClassDue DateAssignmentClassDue DateAssignmentClassDue
Date
222777121212
333888131313
444999141414
555101010151515

<tbody>
</tbody>

What I need are two macros (If they are even possible)
1) A macro that will move cells up when assignments are deleted, but keep the formatting and shape of the table. So if I deleted assignment 3, every assignment after that would move up or over accordingly. So for 4 and 5 would move up, 7 would come to column 1 etc... Think of it has taking a really long table and condensing it into a shorter but wider table.

2) A macro that will sort across multiple selections automatically. So say the due date for assignment 13 changed to where is was due before assignment 4 it would automatically move there and everything would move down and over accordingly. Or if I added an assignment to the end of the list that had a due date in the middle it would automatically move it where it needed to go.

I'm willing to do either of these macros with form buttons if they aren't possible to do automatically. I just this excel sheet to keep track of my reading and attendance so this will just make it perfect and help me keep track of everything this semester. I know I have two pretty tall orders but I have done some macros in the past but I am totally stumped on this one. Any help you guys have would be awesome.

P.s. Because of the other contents on the sheet, each column is only 20 pixels wide and have been merged if that affects anything. Here is a break down of how many columns each "assignment" "Class" and "Due Date" column is made of.
Assignment = 7 columns
Class = 2 columns
Due Date = 3 columns
 

Excel Facts

Can you sort left to right?
To sort left-to-right, use the Sort dialog box. Click Options. Choose "Sort left to right"
Can you not hold the information in one long list elsewhere so that's its easier to maintain and work with, and call the information into this required format so all is in order etc? Personally, I avoid merged cells like the clap, they have only ever caused me issues!
 
Upvote 0
Yeah, I'm currently setting that up right now. That is what I was going to do in the mean time. I just don't like to have to do work in one place just to look at it the way I want in another. I have pretty much been able to set everything up the way I needed it too with having to call information in but I guess we can't always get what we want haha.

The only problem I have with doing it this way is that whenever I delete an assignment it returns a reference error instead of continuing to look at the new cell contents.
 
Upvote 0
Can you not use a form to enter the new information and delete information, that way you'll never need to go to or view the data listing? Also, if you set up the delete to remove the data and then reorder the remaining entries, you can have the information which is called into the 'visual' table loop down and return entries on a descending basis, thus always returning all entires, without error, even when deleting an entry. Seems to work well in my head lol.
 
Upvote 0

Forum statistics

Threads
1,215,883
Messages
6,127,544
Members
449,385
Latest member
KMGLarson

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top