Microsoft Office Forums

Go Back   Microsoft Office Forums > >

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #9  
Old 05-31-2016, 04:39 AM
jeffreybrown jeffreybrown is offline Creating a master spreadsheet for sorting information Windows Vista Creating a master spreadsheet for sorting information Office 2007
Expert
 
Join Date: Apr 2016
Posts: 673
jeffreybrown has a spectacular aura aboutjeffreybrown has a spectacular aura about
Default

I don't have much time this morning, but a couple of things.

If you look at the code, I left a line in there to delete the row which was just moved.

Code:
Private Sub Worksheet_Change(ByVal Target As Range)
    Dim sname As String
    Dim rng As Range
    Set rng = Target.Parent.Range("I:I")
    If Target.Count > 1 Then Exit Sub
    If Intersect(Target, rng) Is Nothing Then Exit Sub
    sname = Range("I" & Target.Row).Value
    Target.EntireRow.Copy Worksheets(sname).Range("A" & Rows.Count).End(xlUp).Offset(1, 0)
    Target.EntireRow.Delete
End Sub
Also, the reason for the example I choose column I is because A if the drop down is in A then the row would transfer before all the information is filled in.

Seems going from left-to-right would be the better way and then transfer info when you get to the end.

I feel I might be missing something so please fill in the gaps where I don't understand.
Reply With Quote
 



Similar Threads
Thread Thread Starter Forum Replies Last Post
Creating a master spreadsheet for sorting information Macro to open Multiple files and copy information to a master file gbaker Excel Programming 2 04-08-2016 08:44 AM
One formula required to copy information from YTD spreadsheet onto individual monthly spreadsheets. Jo Freeman Excel 4 10-28-2015 08:09 AM
Creating a list and sorting alphabetically. irvsax Word 4 09-04-2013 11:47 PM
Creating a master spreadsheet for sorting information Creating a sorting method. Balliol Word 2 07-25-2013 06:18 AM
CAUTION!! Sorting a spreadsheet with hidden columns will trash your data. psmaster@earthlink.net Excel 0 11-24-2009 11:54 AM

Other Forums: Access Forums

All times are GMT -7. The time now is 09:49 PM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft