Results 1 to 3 of 3

Copy Master worksheet data to other sheets!

Threaded View

  1. #3
    Registered User
    Join Date
    10-20-2008
    Location
    India
    Posts
    8
    Hello ,

    You can create a macro that looks like this

    sub tes()
      dim Mastersheets as worksheet
      dim tempMain as worksheet
      dim temp as string
    dim cardnumber as string
    
    
    set Mastersheet = worksheets("Master")
    set tempMain = worksheets("Main")
    
    Mastersheet.activate
    range("A2").activate
    
    temp= activecell.value
    while len(temp)>0 
     if instr(1,temp,"Main")> 0 then
     cardnumber = activecell.offset(0,1).value
     tempmain.activate
     activecell.value= temp
     activecell.offset(0,1).value = cardnumber
    activecell.offset(1,0).activate
     mastersheet.activate
     end if   
    activecell.offset(1,0).activate
    temp=activecell.value
    loop
    
    end sub
    Hope above macro helps you.
    Last edited by shg; 10-20-2008 at 06:55 PM. Reason: add code tags

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Macro to populate a cell and then execute another macro
    By andrewc in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 02-29-2008, 02:19 PM
  2. macro to create a macro?
    By jojotherider in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 02-21-2008, 08:34 PM
  3. Macro for copy/insert into expanding table
    By Soslowgt in forum Excel Programming / VBA / Macros
    Replies: 15
    Last Post: 02-06-2008, 07:24 PM
  4. How to splitt texts into words? (collecting word and compounds)
    By wali in forum Excel Programming / VBA / Macros
    Replies: 53
    Last Post: 02-03-2008, 04:06 AM
  5. Conditional formatting macro (highlight macro)
    By c991257 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 05-09-2007, 02:46 PM

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