+ Reply to Thread
Results 1 to 5 of 5

Find - Replace - Sort: code upgrade

  1. #1
    Registered User
    Join Date
    06-28-2010
    Location
    Posen, Poland
    MS-Off Ver
    Excel 2000
    Posts
    46

    Find - Replace - Sort: code upgrade

    hi,
    I need your help to modified below codes.
    I want replace for example in columns A:C the numbers 3, 4, 12 to number 99, in columns D:F the numbers 5, 6, 18 also to number 99, in columns G:I the numbers 2, 4, 6 to number 99, and so on, in this case every 3 columns. Below code doesn't work.

    Please Login or Register  to view this content.
    And I need help to modified, code to sort for example every 3 columns
    Please Login or Register  to view this content.
    especially, below lines
    Please Login or Register  to view this content.
    to simpliest one line

    I hope so understand
    Thanks

  2. #2
    Valued Forum Contributor MaczaQ's Avatar
    Join Date
    06-03-2011
    Location
    Poland
    MS-Off Ver
    Excel 2003 / XP
    Posts
    510

    Re: Find - Replace - Sort: code upgrade

    first part (Replace) solved here:

    Please Login or Register  to view this content.
    Best Regards
    MaczaQ
    ---------------------------------------------------------------------------------------------------------------------------
    If you are satisfied with the solution(s) provided, please mark your thread as Solved
    If you are pleased with my answer consider to rate it. To thank someone who has helped you, click on the star icon below their name.
    - This way you will add him some reputation points ... thanks in advance.

  3. #3
    Registered User
    Join Date
    06-28-2010
    Location
    Posen, Poland
    MS-Off Ver
    Excel 2000
    Posts
    46

    Re: Find - Replace - Sort: code upgrade

    thanks a lot,
    today I try your code in a few hours, I hope so work
    but, I need simpliest record this line:
    Please Login or Register  to view this content.
    , not ranges, A:C and so on, but for example every 3 columns
    and below line
    Please Login or Register  to view this content.
    can I this way?:
    Please Login or Register  to view this content.
    Maybe someone have an idea for second code?

    ps. I'm using excel 2000 and 2003

    thank you once more again maczaq

  4. #4
    Valued Forum Contributor MaczaQ's Avatar
    Join Date
    06-03-2011
    Location
    Poland
    MS-Off Ver
    Excel 2003 / XP
    Posts
    510

    Re: Find - Replace - Sort: code upgrade

    Hello,

    Updated code below. I created a loop through each 3 columns till macro will find empty range (coArr is without changes). That what You wrote about coArr is only notation. Thats mean it is the same as I wrote only using "_" you can break a line and write code in two or more lines

    Please Login or Register  to view this content.
    You should remember that macro takes values to change from coArr for next index every loop is step to next area (3 columns) If you will have more columns you should remember to update coArr Array otherwise you will get an error about "Subscription out of range"
    Last edited by MaczaQ; 08-03-2012 at 11:10 AM.

  5. #5
    Registered User
    Join Date
    06-28-2010
    Location
    Posen, Poland
    MS-Off Ver
    Excel 2000
    Posts
    46

    Re: Find - Replace - Sort: code upgrade

    yeah, that's it!
    thank you again maczaq

    any other help to simpliest record second code?:
    Please Login or Register  to view this content.

+ 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