ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Prompting user to enter number of cells to be used (https://www.excelbanter.com/excel-programming/387973-prompting-user-enter-number-cells-used.html)

GainesvilleWes via OfficeKB.com

Prompting user to enter number of cells to be used
 
Morning,
I ran a few searches, but am not entirely sure what i should be asking for.
So i apologize if I missed the answer to my question.

I am attempting to develop an Excel worksheet that will ultimately pull the
data into a word doc using the Copy - Paste Special method.
What i am wondering is that in one section of the word doc is a Requirements
page. This page can have anywhere from 1 to 50 separate line items on it.
Each one is numbered, (1. 2. 3., etc)
Instead of just creating 50 numbered lines and using 50 cells in the excel
worksheet then going back after updating the information on the word doc and
deleting the blank numbers not used, can i either:

a) on the excel worksheet, prompt the user to enter how many numbers they
will require, then somehow write a macro to pull the information over into
the word doc. (i am not sure how i would do this without presetting the Copy -
Paste Special)


b) write a word macro to auto erase the unused numbers after updating

Now option 'b' sounds like it would be easier to code, but i am not sure
where to begin with that.

Thank you in advance.

--
Message posted via OfficeKB.com
http://www.officekb.com/Uwe/Forums.a...mming/200704/1


joel

Prompting user to enter number of cells to be used
 
You could automate the whole process. You could search for Requirements in
the excel workshhet and then take all the requirements in adjacent rows
leaving a blank cell after the last requirement. Then excel macro simply
needs to copy the information until it finds an empty cell.

"GainesvilleWes via OfficeKB.com" wrote:

Morning,
I ran a few searches, but am not entirely sure what i should be asking for.
So i apologize if I missed the answer to my question.

I am attempting to develop an Excel worksheet that will ultimately pull the
data into a word doc using the Copy - Paste Special method.
What i am wondering is that in one section of the word doc is a Requirements
page. This page can have anywhere from 1 to 50 separate line items on it.
Each one is numbered, (1. 2. 3., etc)
Instead of just creating 50 numbered lines and using 50 cells in the excel
worksheet then going back after updating the information on the word doc and
deleting the blank numbers not used, can i either:

a) on the excel worksheet, prompt the user to enter how many numbers they
will require, then somehow write a macro to pull the information over into
the word doc. (i am not sure how i would do this without presetting the Copy -
Paste Special)


b) write a word macro to auto erase the unused numbers after updating

Now option 'b' sounds like it would be easier to code, but i am not sure
where to begin with that.

Thank you in advance.

--
Message posted via OfficeKB.com
http://www.officekb.com/Uwe/Forums.a...mming/200704/1



GainesvilleWes via OfficeKB.com

Prompting user to enter number of cells to be used
 
Nice. Thank you.
One question though: On the word document; how would i get each 'line item'
individually numbered?

Joel wrote:
You could automate the whole process. You could search for Requirements in
the excel workshhet and then take all the requirements in adjacent rows
leaving a blank cell after the last requirement. Then excel macro simply
needs to copy the information until it finds an empty cell.

Morning,
I ran a few searches, but am not entirely sure what i should be asking for.

[quoted text clipped - 20 lines]

Thank you in advance.


--
Message posted via OfficeKB.com
http://www.officekb.com/Uwe/Forums.a...mming/200704/1


joel

Prompting user to enter number of cells to be used
 
Include the numbers in excel.
1) Requirement A
2) Requirement B
3) Requirement C

"GainesvilleWes via OfficeKB.com" wrote:

Nice. Thank you.
One question though: On the word document; how would i get each 'line item'
individually numbered?

Joel wrote:
You could automate the whole process. You could search for Requirements in
the excel workshhet and then take all the requirements in adjacent rows
leaving a blank cell after the last requirement. Then excel macro simply
needs to copy the information until it finds an empty cell.

Morning,
I ran a few searches, but am not entirely sure what i should be asking for.

[quoted text clipped - 20 lines]

Thank you in advance.


--
Message posted via OfficeKB.com
http://www.officekb.com/Uwe/Forums.a...mming/200704/1



GainesvilleWes via OfficeKB.com

Prompting user to enter number of cells to be used
 
I see what you are saying....nice.

You wouldnt happen to have a handy prewritten macro to search would you?

Joel wrote:
Include the numbers in excel.
1) Requirement A
2) Requirement B
3) Requirement C

Nice. Thank you.
One question though: On the word document; how would i get each 'line item'

[quoted text clipped - 10 lines]

Thank you in advance.


--
Message posted via OfficeKB.com
http://www.officekb.com/Uwe/Forums.a...mming/200704/1


joel

Prompting user to enter number of cells to be used
 
I re-read your previous posting. No mention about any searches. You need to
be more specific what type of search you are requesting.

"GainesvilleWes via OfficeKB.com" wrote:

I see what you are saying....nice.

You wouldnt happen to have a handy prewritten macro to search would you?

Joel wrote:
Include the numbers in excel.
1) Requirement A
2) Requirement B
3) Requirement C

Nice. Thank you.
One question though: On the word document; how would i get each 'line item'

[quoted text clipped - 10 lines]

Thank you in advance.


--
Message posted via OfficeKB.com
http://www.officekb.com/Uwe/Forums.a...mming/200704/1



GainesvilleWes via OfficeKB.com

Prompting user to enter number of cells to be used
 
I was using the fourm search function to find any previous post regarding my
questions, (a and b in my first post).

Then you offered a better idea of how to solve my issue.
Now i just need to figure out how to write a macro to pull all information
from the excel to the word document until it hits a blank cell.

any insight on how to accomplish that?

Joel wrote:
I re-read your previous posting. No mention about any searches. You need to
be more specific what type of search you are requesting.

I see what you are saying....nice.

[quoted text clipped - 10 lines]

Thank you in advance.


--
Message posted via OfficeKB.com
http://www.officekb.com/Uwe/Forums.a...mming/200704/1


joel

Prompting user to enter number of cells to be used
 
to select the cells you need something like this

Sub abc()

mylastrow = Cells(2, "A").End(xlDown).Row
Range(Cells(2, "A"), Cells(mylastrow, "A")).Select

End Sub

"GainesvilleWes via OfficeKB.com" wrote:

I was using the fourm search function to find any previous post regarding my
questions, (a and b in my first post).

Then you offered a better idea of how to solve my issue.
Now i just need to figure out how to write a macro to pull all information
from the excel to the word document until it hits a blank cell.

any insight on how to accomplish that?

Joel wrote:
I re-read your previous posting. No mention about any searches. You need to
be more specific what type of search you are requesting.

I see what you are saying....nice.

[quoted text clipped - 10 lines]

Thank you in advance.


--
Message posted via OfficeKB.com
http://www.officekb.com/Uwe/Forums.a...mming/200704/1



GainesvilleWes via OfficeKB.com

Prompting user to enter number of cells to be used
 
Okay. I am assuming that code will highlight the rows that hold the data
ending at the blank row. Now, how would I get the highlighted information to
copy over to the word document in the specific place i need?

Joel wrote:
to select the cells you need something like this

Sub abc()

mylastrow = Cells(2, "A").End(xlDown).Row
Range(Cells(2, "A"), Cells(mylastrow, "A")).Select

End Sub

I was using the fourm search function to find any previous post regarding my
questions, (a and b in my first post).

[quoted text clipped - 13 lines]

Thank you in advance.


--
Message posted via http://www.officekb.com


GainesvilleWes via OfficeKB.com

Prompting user to enter number of cells to be used
 
Also, thank you for all the time you have spent so far assisting me. It is
greatly appreciated.


Joel wrote:
to select the cells you need something like this

Sub abc()

mylastrow = Cells(2, "A").End(xlDown).Row
Range(Cells(2, "A"), Cells(mylastrow, "A")).Select

End Sub

I was using the fourm search function to find any previous post regarding my
questions, (a and b in my first post).

[quoted text clipped - 13 lines]

Thank you in advance.


--
Message posted via OfficeKB.com
http://www.officekb.com/Uwe/Forums.a...mming/200704/1



All times are GMT +1. The time now is 07:48 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com