+ Reply to Thread
Results 1 to 7 of 7

Code to sort after moves between tab

  1. #1
    Forum Contributor
    Join Date
    08-19-2009
    Location
    uk
    MS-Off Ver
    Excel 2010
    Posts
    147

    Code to sort after moves between tab

    Hi all,

    I have a macro that moves a line of information between open and closed tabs depending on if the issue is set to O or C (column J in the attached file). It works perfectly except that it doesnt keep the issue order (column A) when it moves between tabs. Can anyone help me alter the code so that after it does the move it sorts it by column A so the issues are in order?

    Many thanks,

    Chemist

    Please Login or Register  to view this content.
    Last edited by Chemistification; 09-08-2010 at 10:42 AM.

  2. #2
    Forum Expert Domski's Avatar
    Join Date
    12-14-2009
    Location
    A galaxy far, far away
    MS-Off Ver
    Darth Office 2010
    Posts
    3,950

    Re: Code to sort after moves between tab

    Try:

    Please Login or Register  to view this content.

    Dom
    "May the fleas of a thousand camels infest the crotch of the person who screws up your day and may their arms be too short to scratch..."

    Use code tags when posting your VBA code: [code] Your code here [/code]

    Remember, saying thanks only takes a second or two. Click the little star to give some Rep if you think an answer deserves it.

  3. #3
    Forum Contributor
    Join Date
    08-19-2009
    Location
    uk
    MS-Off Ver
    Excel 2010
    Posts
    147

    Re: Code to sort after moves between tab

    HI Domski,

    I put the code that you suggested into the origional code but can't seem to get it to work. I opened up the vba editor and then put your code inbetween the bits where it says start with and end with. Then i tried the macro again but it doesnt seem to sort after changing between tabs. Any ideas where im going wrong?

  4. #4
    Forum Expert Domski's Avatar
    Join Date
    12-14-2009
    Location
    A galaxy far, far away
    MS-Off Ver
    Darth Office 2010
    Posts
    3,950

    Re: Code to sort after moves between tab

    That's odd. Would you be able to upload a sample workbook so I can have a look what's going on?

    Dom

  5. #5
    Forum Contributor
    Join Date
    08-19-2009
    Location
    uk
    MS-Off Ver
    Excel 2010
    Posts
    147

    Re: Code to sort after moves between tab

    Hi Domski,

    Sorry had something to do. I reopened the spreadsheet and did the same thing again and guess what... works perfectly. Cheers loads for the solution and sorry for doubting....

  6. #6
    Forum Contributor
    Join Date
    08-19-2009
    Location
    uk
    MS-Off Ver
    Excel 2010
    Posts
    147

    Re: Code to sort after moves between tab

    Domski how would i make it so it does exactly the same but going from open issues to closed? This only sorts it one way?

    Cheers in advance

  7. #7
    Forum Expert Domski's Avatar
    Join Date
    12-14-2009
    Location
    A galaxy far, far away
    MS-Off Ver
    Darth Office 2010
    Posts
    3,950

    Re: Code to sort after moves between tab

    I assume you have a similar change event code on the Open Issues worksheet's code page? The same modification to the code should work for that.

    Dom

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1