Solved

How can I select the 101 cell from my excel sheet

Posted on 2016-08-13
7
39 Views
Last Modified: 2016-08-13
How can I select the 101 cell from my excel sheet and repeat the same thing for the next 100 cell. My cells are selected within the colored area in the attached file.

Regards,

Dallag
File1.xlsx
0
Comment
Question by:Mohammed Dallag
  • 4
  • 3
7 Comments
 
LVL 30

Expert Comment

by:Subodh Tiwari (Neeraj)
ID: 41754947
Please try this....
In the attached, click the button "Click To Select" to run the code. The code will prompt you to input the occurrence of 101th cell you want to select. So if you want to select the first occurrence, input 1 in the inputbox and click OK. So you can keep on selecting the 101th cell by inputting it's occurrence.

If you have any issue with downloading and opening the file, first download ans save the file on your system and then open it.

Sub Select101thCell()
Dim rng As Range
Dim n As Integer
n = Application.InputBox("Which occurrence of 101th cell you want to select? (e.g. 1,2,3...)", Type:=1)
Set rng = Range("A:F")
If n <> 0 Then rng.Cells(101 * n).Select
End Sub

Open in new window

File1.xlsm
0
 

Author Comment

by:Mohammed Dallag
ID: 41755193
Dear Subodh Tiwari,

I need to save that number of cells in another column. Could you help in this?

Regards,

Dallag
0
 
LVL 30

Expert Comment

by:Subodh Tiwari (Neeraj)
ID: 41755194
Hi Dallag,

Not sure about your requirement. Would you please elaborate each step you would like to automate?
And if possible, please upload another sample workbook with the desired output mocked up manually.
0
Networking for the Cloud Era

Join Microsoft and Riverbed for a discussion and demonstration of enhancements to SteelConnect:
-One-click orchestration and cloud connectivity in Azure environments
-Tight integration of SD-WAN and WAN optimization capabilities
-Scalability and resiliency equal to a data center

 

Author Comment

by:Mohammed Dallag
ID: 41755195
Dear Subodh Tiwari,

I want just to save the numbers in a list after I select them. I created sheet2 and I put the cells selected in the attached file. I number of cells depend on the range of the data.

Regards,

Dallag
File2.xlsm
0
 
LVL 30

Accepted Solution

by:
Subodh Tiwari (Neeraj) earned 500 total points
ID: 41755198
Okay please refer to the attached and click the button to run the code.
File2.xlsm
0
 

Author Closing Comment

by:Mohammed Dallag
ID: 41755199
Thank you
0
 
LVL 30

Expert Comment

by:Subodh Tiwari (Neeraj)
ID: 41755200
You're welcome Dallag! Glad to help.
0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction This Article briefly covers methods of calculating the NPV and IRR variants in Excel as well as the limitations in calculating and interpreting IRR results. Paraphrasing Richard Shockley, author of my favourite finance reference tex…
Improved? Move/Copy Add-in Replacement - How to avoid the annoying, “A formula or sheet you want to move or copy contains the name XXX, which already exists on the destination worksheet.” David Miller (dlmille)  It was one of those days… I wa…
The viewer will learn how to use a discrete random variable to simulate the return on an investment over a period of years, create a Monte Carlo simulation using the discrete random variable, and create a graph to represent the possible returns over…
Although Jacob Bernoulli (1654-1705) has been credited as the creator of "Binomial Distribution Table", Gottfried Leibniz (1646-1716) did his dissertation on the subject in 1666; Leibniz you may recall is the co-inventor of "Calculus" and beat Isaac…

856 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question