将数据拆分为多个工作表 [英] Split Data into Multiple worksheets

查看:68
本文介绍了将数据拆分为多个工作表的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

您好,

I有一个工作簿,我每周输入数据。  我想将数据拆分为基于A列的单独工作表。我希望数据保持在我在主
工作表中输入的顺序。  我还需要每周更新此工作表,并希望将更新的信息传输到其他工作表。  我有excel的基本知识,但我对VBA和宏的限制,所以任何帮助将不胜感激。  工作簿
有9列和无限行数。  我将在今年余下的时间里使用它,因此在我完成时它最多可以有600行。  目前我将信息输入到工作表中,然后将信息复制并传递到我需要的其他工作表中。  我
知道有一种更简单的方法可以做到这一点,但目前我不知所措。  我已经下载了一些add'ins,它将完成我想要的部分,但它总是
重组  工作表基于另一列中的日期。

I have a workbook that I enter data into on a weekly basis.  I would like to split the data into separate worksheets based on column A.  I would like the data to stay in the order that I have entered it on the main worksheet.  I also need to update this sheet weekly and would like the updated info to transfer to the other worksheets.  I have basic knowledge of excel but I am limited on VBA and macros so any help would be greatly appreciated.  The workbook has 9 columns and unlimited # of rows.  I will use this for the rest of the year so it could have up to 600 rows by the time I am finished.  Currently I type the info into on sheet and copy and past the info into the other sheets I need.  I know there is an easier way to do this but currently I am at a loss.  I have downloaded some add'ins and it will do part of what I would like but it will always reorganize the sheet based upon a date that is in another column.

谢谢!

Kim

推荐答案

要编写VBA代码并确保它完全符合您的要求,我真的需要一份工作簿。但是,您已指出要复制的数据取决于A列,因此您可以尝试以下操作,看看它最初是否符合您的
要求。

To write VBA code and be sure that it does exactly as you want I would really need a copy of your workbook. However, you have indicated that the data to be copied is dependent on column A so you could try the following and see if initially it does what you require.


  • 在主工作表上选择所有数据,然后选择AutoFilter。 (要应用自动筛选,请选择首页功能区,然后选择最右侧选择"排序和过滤" - >>"过滤")。
  • 选择A列标题中的DropDown,然后选择所需的筛选选项。
  • 选择所有可见数据,然后选择右键和复制。 (您应该在各种连续选择周围看到"爬行蚂蚁"。)
  • 选择所需的工作表并单击第一个单元格并粘贴。
  • 对剩余的重复上述操作A列中的选项。 

如果您将工作簿转到上述状态,然后将副本上传到OneDrive,那么我很可能会提供代码将每行复制为您完成它。

If you get the workbook to the above state and then upload a copy to OneDrive then I can most likely provide code to copy each row as you complete it.

但是,它确实需要主工作表中每条记录的唯一标识符,因此您可以确认它具有该标识,或者可以将其添加到单独的列中。如果您还没有唯一标识符,则可以将其自动化。

However, it really needs a unique identifier for each record in the master worksheet so can you confirm it you have that or can it be added in a separate column. It is possible to automate the unique identifier if you don't already have it.

还需要知道您希望将记录复制到哪个阶段。例如。填充特定行的所有字段后。

Also need to know at what stage you want the record copied. eg. After all fields of the particular row are populated.

在OneDrive上上载工作簿的准则。 (如果您已经使用OneDrive并且保存到它的过程不同,那么您可以从步骤8开始获取链接,但请在上传之前压缩文件。)

Guidelines to upload a workbook on OneDrive. (If you already use OneDrive and your process for saving to it is different then you can probably start at step 8 to get the link but please zip the file before uploading.)


  1. 压缩工作簿。不要只是将解压缩的工作簿保存到OneDrive,因为工作簿使用On-Line Excel打开,并且使用On-Line版本的有限功能会导致问题。
  2. 要压缩文件:在Windows资源管理器中右键单击所选文件,然后选择发送至 - >压缩(zipped)文件夹)。通过按住Ctrl键并在每个文件上单击鼠标左键,您可以选择多个工作簿,然后右键单击其中一个选项
    以发送到压缩文件,它们将全部包含在一个Zip文件中。
  3. 不要使用第三方压缩应用程序,因为我无法解压缩它们。当Windows提供完美的应用程序时,我不会使用第三方应用程序阻塞我的计算机。
  4. 转到此链接。  https://onedrive.live.com
  5. 使用您在此论坛中使用的相同登录ID和密码。
  6. 在顶部的蓝色栏中选择上传,然后浏览到要上传的压缩文件夹。
  7. 选择打开(或双击)。 (请耐心等待,并在最初看到弹出窗口表示已完成后给它时间显示文件。)
  8. 右键单击OneDrive上的文件,然后选择共享。
  9. 选择"获取"一个链接"从弹出菜单中。
  10. 单击显示链接的字段,然后突出显示,然后将链接复制并粘贴到此论坛的回复中。 (我建议您避开"获取链接"屏幕上的"复制"按钮,因为它会引入不需要的额外步骤
    。)
  1. Zip your workbooks. Do not just save an unzipped workbook to OneDrive because the workbooks open with On-Line Excel and the limited functionality with the On-Line version causes problems.
  2. To Zip a file: In Windows Explorer Right click on the selected file and select Send to -> Compressed (zipped) folder). By holding the Ctrl key and left click once on each file, you can select multiple workbooks before right clicking over one of the selections to send to a compressed file and they will all be included into the one Zip file.
  3. Do not use 3rd party compression applications because I cannot unzip them. I do not clog up my computer with 3rd party apps when there are perfectly good apps supplied with windows.
  4. Go to this link.  https://onedrive.live.com
  5. Use the same login Id and Password that you use for this forum.
  6. Select Upload in the blue bar across the top and browse to the zipped folder to be uploaded.
  7. Select Open (or just double click). (Be patient and give it time to display the file after initially seeing the popup indicating it is done.)
  8. Right click the file on OneDrive and select Share.
  9. Select "Get a Link" from the popup menu.
  10. Click in the field displaying the link and it should highlight and then Copy and Paste the link into your reply on this forum. (I suggest that you avoid the "Copy" button on the "Get a link" screen because it introduces additional steps that are not required.)


这篇关于将数据拆分为多个工作表的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆