Microsoft Office

Microsoft Office Questions? Ask a IT Expert for Support ASAP

Ask a Computer Expert,
Get an Answer ASAP!

Microsoft Office
This answer was rated:

Need a macro to search a worksheet

with 2000 rows of employee...
Need a macro to search a worksheet with 2000 rows of employee data. Once it identifies employee by employee data I want it to copy multiple fields of data for that employee to a second worksheet located in a different workbook. Can someone tell me is this is possible. I tried and because it copies the exact cells, I can only run the macro once. If I run it a second time, it ignores new search criteria.
Show More
Show Less
Ask Your Own Microsoft Office Question
Answered in 2 minutes by:
10/23/2013
The-PC-Guy
The-PC-Guy, Computer Manager
Category: Microsoft Office
Satisfied Customers: 2,085
Experience: 20 years experience providing remote computer support
Verified

The-PC-Guy :

Thanks for using JustAnswer. My name isXXXXX will do whatever I can to answer your question

The-PC-Guy :

Yes this is possible

The-PC-Guy :

can you send me a copy of the workbook in question so I can see how your data is arranged.

The-PC-Guy :

you can upload your workbook to www.wikisend.com

The-PC-Guy :

after uploading they give you a file ID

The-PC-Guy :

paste that here.

The-PC-Guy :

Actaully if you want to copy from one sheet to another workbook, I will need a copy of both workbooks to be able to do this for you.

The-PC-Guy
The-PC-Guy, Computer Manager
Category: Microsoft Office
Satisfied Customers: 2,085
Experience: 20 years experience providing remote computer support
Verified
The-PC-Guy and 87 other Microsoft Office Specialists are ready to help you
Ask your own question now
The-PC-Guy :

Thanks for using JustAnswer. My name isXXXXX will do whatever I can to answer your question

The-PC-Guy :

Yes this is possible

The-PC-Guy :

can you send me a copy of the workbook in question so I can see how your data is arranged.

The-PC-Guy :

you can upload your workbook to www.wikisend.com

The-PC-Guy :

after uploading they give you a file ID

The-PC-Guy :

paste that here.

The-PC-Guy :

Actaully if you want to copy from one sheet to another workbook, I will need a copy of both workbooks to be able to do this for you

Ask Your Own Microsoft Office Question
Customer reply replied 4 years ago

I am out at the moment will be home to upload in 45 minutes. Hope to have this by morning is that possible

shouldn't be a problem once I understand what you need.

Hopefully you will be a round after uploading to answer any clarifications I may need to help you.

But from my basic understanding.

You can a column of ID numbers

you want the macro to prompt for an ID number.

Then take whatever data is in any row that matches that ID number,

copy that row to another workbook,

then delete the original row?
Ask Your Own Microsoft Office Question
Customer reply replied 4 years ago


I uploaded two workbooks:


 


One is a template where the data needs to be copied and pasted in yellow boxes. http://wikisend.com/download/135570/Template.xlsx


 


Two is the data file. http://wikisend.com/download/439368/ALPHA Report.xlsx


 


I want to start with opening the template and selecting a macro button that opens the data file. Once at the data file, I need an input or find box to pop up so that I can key in perno to search for an employee. Once It finds the employee row, I want to cut and paste the required fields to the template in the yellow boxes. The next time I need a new workbook for another employee, I want to open the Template (where macro resides) click on the button, key in the perno (input) and have it look up the employee in the data workbook and copy and paste it over the template.

so just to be clear on this

1. you are going to open the template file, and you want to click a button to run the macro which will be contained in the template file.

2. Then it will prompt you to select another workbook, this will contain the data. or will the data file always be the same, so it can be automatically opened?

3. Then you will be prompted for an ID number which is located in column B of the data file, we will then copy/concatenate the appropriate fields that are in yellow, over to the yellow boxes in the template file Sheet 1?

4. Then do we delete the row from the data file that we just copied, or do we leave it there?

Thanks
Ask Your Own Microsoft Office Question
Customer reply replied 4 years ago

1. Yes open template to start process every time


2. Do not need a prompt, just automatically open file as it will always be the same name in the same location.


3. Yes, prompt to input or find ID number in column B. Copy/concatenate the appropriate fields from data workbook to template workbook. Example first name & last name will be concatenate to be copied to Employee Name Field. Salary will be copied over to salary field in yellow.


4. Good question. Once everything is copied to template workbook it will be saved out with a new name. The template is always empty so if user is going to use it again before closing, need a reset button to clean out fields. I know how to create reset macro and button.

ok

gotya.
Ask Your Own Microsoft Office Question

i have this done for you.

http://wikisend.com/download/691838/Template.xlsm

 

also remember you will have to change the file name in the worksheet open to match where your file is located

let me know if you need any modifications

PLEASE REMEMBER TO RATE MY SERVICE

YOU DO SO WITH THE SMILEYS BENEATH THIS CHAT WINDOW

Ask Your Own Microsoft Office Question
Customer reply replied 4 years ago

I will place macro in my workbooks and see if I can make work and
understand. Will review first thing in morning and see if I have any
questions. Thank you. Don't close my case just yet.

ok, I will be here if you need anything
Ask Your Own Microsoft Office Question
Customer reply replied 4 years ago


This macro has done exactly what I want. You are Wonderful! SmileBefore I finalize and provide you with your rating. Have questions.


 


I transferred macro over to my real workbook which has personal data in it that is confidential. I replaced file names and locations and actual cells but once I input the perno, it is not working. I think it is because the sheets have real names and may not be necessarily in the sheet 1 placement in the workbook. Do I have to do something to convert the Sheet 1 to real tab name Input which is the first tab and Sheet 1 in the other workbook to DS which is really sheet 3?

that is correct, everywhere it refers to a sheet name, and I think there are about 4 or 5 spots. you would have to put the appropriate name. So for example

if you have something like

worksheets("Sheet 1").activate

you would change to

worksheets("Whatever your sheet name is").activate

remember that sheets are also specific to workbook.

I think i do a workbook.activate meathod a couple of times.

so where it says

workbooks("workbook name").activate

obviously that would refer to that workbook

and any

worksheets.activate functions following refer to that workbook

until you get to the next

workbooks.activate

then all sheets refer to that workbook.

hope this makes sense.

Let me know if you still get stuck.
Ask Your Own Microsoft Office Question
did that help?

If you are still having trouble.

Could I remote into your computer and help you. You would be able to see everything I am doing.

Let me know.
Ask Your Own Microsoft Office Question
Customer reply replied 4 years ago

I tried one more thing. If this doesn't work, I would appreciate your accessing my computer.


Placed in Wikisend:


 


These are the actual files. I had to remove a lot of confidential info, but I altered the macro to fit cells and filenames.


 


http://wikisend.com/download/548932/Banded Salary Promo Workup Tool.xlsm


 


http://wikisend.com/download/666234/Alpha for SAL Workup.xls

ok

first of all

this line

Workbooks("C:\Documents and Settings\chavispb\Desktop\SALWORKUP\Banded Salary Promo Workup Tool.xlsm").Activate

change it to just the file name, without the extension since this workbook is already open excel will find it as an object

so it should look like this

Workbooks("Banded Salary Promo Workup Tool").Activate

finally when you enter a number to search for, do not enter any leading 0000s

because the way excel evaluates it is as an integer and leading 00000s are automatically stripped off.

so if you are searching for 00054282 for example, you would enter that as 54282, and it will work.

if that gets confusing for the user you can change the cell format to general in column b of the


http://wikisend.com/download/666234/Alpha for SAL Workup.xls

 

file

 

and it will strip out all of the zeros that are displayed.

 

hope this helps.

 

if it still does not let me know and I will do the remote



Ask Your Own Microsoft Office Question
whats the latest?

Did you finally get it to work?

If you are still struggling then let me do the remote and help you.

Anything I see will be kept confidential.

Let me know
Ask Your Own Microsoft Office Question
Customer reply replied 4 years ago


It is working wonderfully. I just couldn't figure out how to respond back to you without this reply box. I want to provide you with an SmileEXCELLENT SERVICESmile Rating but I can't select the rating provided. Can you provide guidance for how I can provide feedback? I really appreciate all the work you did. Your understanding and patience, as well as your knowledge is incredible. I am so glad that I found you online. I would never have been able to complete this project without you. You are a star and have made me one as well.

Thanks

I will ask customer service to contact you to help with the rating process.

---------------------------------------------------------------------------------------------------------------

if you have any questions in the future you can visit my profile

http://www.justanswer.com/computer/expert-1expert-2rulethemall/

and ask a question right in my box,

also you can put "PC Guy only" in your question title if you want to get to me.

---------------------------------------------------------------------------------------------------------------

Let me know if that was unclear
Ask Your Own Microsoft Office Question
Ask The-PC-Guy Your Own Question
The-PC-Guy
The-PC-Guy
The-PC-Guy, Computer Manager
Category: Microsoft Office
Satisfied Customers: 2,085
2,085 Satisfied Customers
Experience: 20 years experience providing remote computer support

The-PC-Guy is online now

A new question is answered every 9 seconds

How JustAnswer works:

  • Ask an ExpertExperts are full of valuable knowledge and are ready to help with any question. Credentials confirmed by a Fortune 500 verification firm.
  • Get a Professional AnswerVia email, text message, or notification as you wait on our site. Ask follow up questions if you need to.
  • 100% Satisfaction GuaranteeRate the answer you receive.

JustAnswer in the News:

Ask-a-doc Web sites: If you've got a quick question, you can try to get an answer from sites that say they have various specialists on hand to give quick answers... Justanswer.com.
JustAnswer.com...has seen a spike since October in legal questions from readers about layoffs, unemployment and severance.
Web sites like justanswer.com/legal
...leave nothing to chance.
Traffic on JustAnswer rose 14 percent...and had nearly 400,000 page views in 30 days...inquiries related to stress, high blood pressure, drinking and heart pain jumped 33 percent.
Tory Johnson, GMA Workplace Contributor, discusses work-from-home jobs, such as JustAnswer in which verified Experts answer people’s questions.
I will tell you that...the things you have to go through to be an Expert are quite rigorous.

What Customers are Saying:

My Expert answered my question promptly and he resolved the issue totally. This is a great service. I am so glad I found it I will definitely use the service again if needed.

One Happy CustomerNew York

Wonderful service, prompt, efficient, and accurate. Couldn't have asked for more. I cannot thank you enough for your help.

Mary C.Freshfield, Liverpool, UK

This expert is wonderful. They truly know what they are talking about, and they actually care about you. They really helped put my nerves at ease. Thank you so much!!!!

AlexLos Angeles, CA

Thank you for all your help. It is nice to know that this service is here for people like myself, who need answers fast and are not sure who to consult.

GPHesperia, CA

I couldn't be more satisfied! This is the site I will always come to when I need a second opinion.

JustinKernersville, NC

Just let me say that this encounter has been entirely professional and most helpful. I liked that I could ask additional questions and get answered in a very short turn around.

EstherWoodstock, NY

Thank you so much for taking your time and knowledge to support my concerns. Not only did you answer my questions, you even took it a step further with replying with more pertinent information I needed to know.

RobinElkton, Maryland

< Previous | Next >

Meet the Experts:

jstinehelfer

jstinehelfer

Information Systems Manager

36 satisfied customers

A+ Comptia Certified computer repair

JasonJames122

JasonJames122

Computer Enthusiast

0 satisfied customers

I manage all information systems (network of Windows PC's and servers with Microsoft Office products) for a small business

Jess M.

Jess M.

Computer Support Specialist

701 satisfied customers

Computer Software Specialist for more than 10 years

The-PC-Guy

The-PC-Guy

Computer Manager

2,085 satisfied customers

20 years experience providing remote computer support

James K.

James K.

Consultant

260 satisfied customers

Technical Director of IT Company

IT Miro

IT Miro

Computer Scientist

157 satisfied customers

Bachelor's Degree in Information Technology, Microsoft Certified Professional

Chris L.

Chris L.

Support Specialist

147 satisfied customers

Certified Expert with over 10 years experience.

< Previous | Next >

Related Microsoft Office Questions
Publisher just shut down and I lost all of my work! Any way
Publisher just shut down and I lost all of my work! Any way to reclaim? … read more
caraleneK
caraleneK
Service Manager
1,676 satisfied customers
I beieve the OCR is available in Windows 10 or Word 2016.
Second opinion] I beieve the OCR is available in Windows 10 or Word 2016. How do I activate it? Bob … read more
bbao
bbao
Freelance IT Consultant
74 satisfied customers
I would like to access ‘my documents' folder. I would like
I would like to access ‘my documents' folder JA: What application are you using? Customer: I would like to access my ‘my documents' folder JA: Have you installed any updates recently? Customer: How do… read more
bbao
bbao
Freelance IT Consultant
74 satisfied customers
Cannot add a shadow on MS WORD rectangle. Lenovo. not sure
Geeksquad attempted this morning suggested I try MS. … read more
Jess M.
Jess M.
Computer Support Specialist
Bachelor's Degree
701 satisfied customers
I recently followed the prompt to update my MS operating
I recently followed the prompt to update my MS operating System, 10. Now when I create a file and try to save it, Word stops working. This is very problematic to getting work done. What's the fix? … read more
George Sibiya
George Sibiya
PhD
217 satisfied customers
I need to start page numbering later in my dissertation. Mw
I need to start page numbering later in my dissertation … read more
The-PC-Guy
The-PC-Guy
Computer Manager
2,085 satisfied customers
I am told that my contact for Microsoft Office has expired.
I am told that my contact for Microsoft Office has expired. I enjoy Office as it is, an element included in my iMac purchase as "Office for Mac". I believe that this lies in a lasting agreement that a… read more
bbao
bbao
Freelance IT Consultant
74 satisfied customers
I need help to access my smilebox account. Desk top computer
probably not-being retired my wife and I reside at a different location and do not have access to this computer … read more
Kris R
Kris R
IT Manager
Computing
2,652 satisfied customers
It stop working in my computer. I cannot save at all, and I
it stop working in my computer. I cannot save at all, and I lost all the files I tried to save since last night. … read more
Bryan
Bryan
IT Consultant
8,751 satisfied customers
I forgot my login password, [email protected], I tried and
I forgot my login password,***@******.***, I tried and tried until blocked out, I now have a new account but I can't removing my old password. … read more
George Sibiya
George Sibiya
PhD
217 satisfied customers
Had office on w 10. lost it all to restore. now I want
had office on w 10. lost it all to restore. now I want office back but don't have a clue what my office key is. help … read more
bbao
bbao
Freelance IT Consultant
74 satisfied customers
I purchased the home edition of Offcie 365 and installed but
I purchased the home edition of Offcie 365 and installed but looks like everything remains 2007. Also I thougtt I was buying a premium outlook separately but ended up being the personal version of 365… read more
bbao
bbao
Freelance IT Consultant
74 satisfied customers
I beieve the OCR is available in Windows 10 or Word 2016.
I beieve the OCR is available in Windows 10 or Word 2016. How do I activate it? Bob … read more
Sheri
Sheri
Bachelor\u0027s Degree
102 satisfied customers
H Hallsey .I tried to sign onto my hotmail account but have
Hello my name is***** .I tried to sign onto my hotmail account but have run into road block after road block .For one thing I originally used***@******.*** for my hotmail adress and***@******.*** as m… read more
Josh
Josh
It Support Specialist
Associate Degree
5,140 satisfied customers
Forgot password. Cannot open e-mail. Outlook. My account was
My account was hacked. Tried to change password. Ran into trouble. Bell helped somewhat, except I lost the ability to reach my messages.… read more
Josh
Josh
It Support Specialist
Associate Degree
5,140 satisfied customers
Documents sent to wrong printer. In addition, wrong network
In addition, wrong network was chosen to the printer where the documents were sent . Home computer. … read more
bbao
bbao
Freelance IT Consultant
74 satisfied customers
Thank you for asking. I am using MacOS 10.13 with MS Word
Thank you for asking. I am using MacOS 10.13 with MS Word for Mac 15.41 and keep getting this message: "You cannot save while the file is in use by another process. Try saving the file with a new name… read more
bbao
bbao
Freelance IT Consultant
74 satisfied customers
My userid has been locked up and I need to install a
my userid has been locked up and I need to install a Microsoft Office … read more
Kris R
Kris R
IT Manager
Computing
2,652 satisfied customers
Disclaimer: Information in questions, answers, and other posts on this site ("Posts") comes from individual users, not JustAnswer; JustAnswer is not responsible for Posts. Posts are for general information, are not intended to substitute for informed professional advice (medical, legal, veterinary, financial, etc.), or to establish a professional-client relationship. The site and services are provided "as is" with no warranty or representations by JustAnswer regarding the qualifications of Experts. To see what credentials have been verified by a third-party service, please click on the "Verified" symbol in some Experts' profiles. JustAnswer is not intended or designed for EMERGENCY questions which should be directed immediately by telephone or in-person to qualified professionals.

Disclaimer: Information in questions, answers, and other posts on this site ("Posts") comes from individual users, not JustAnswer; JustAnswer is not responsible for Posts. Posts are for general information, are not intended to substitute for informed professional advice (medical, legal, veterinary, financial, etc.), or to establish a professional-client relationship. The site and services are provided "as is" with no warranty or representations by JustAnswer regarding the qualifications of Experts. To see what credentials have been verified by a third-party service, please click on the "Verified" symbol in some Experts' profiles. JustAnswer is not intended or designed for EMERGENCY questions which should be directed immediately by telephone or in-person to qualified professionals.

Show MoreShow Less

Ask Your Question

x