How do I select multiple rows randomly in MS Excel?

How do I select multiple rows randomly in MS Excel?
0
Varun (17)
4/18/2005 5:04:07 AM
excel.misc 78881 articles. 5 followers. Follow

2 Replies
399 Views

Similar Articles

[PageSpeed] 51

Hi 
Select your first row and then hold down the Ctrl key while selecting the 
others.

HTH
Michael

"Varun" wrote:

> How do I select multiple rows randomly in MS Excel?
0
4/18/2005 6:26:02 AM
"Varun" <Varun@discussions.microsoft.com> wrote
> How do I select multiple rows randomly in MS Excel?

Just another angle to the post's interp ..
(with emphasis on "randomly")

Here's an example set-up to play with ..

Assume we have 6 rows of data below
in Sheet1's A1:C6:

Data1 Text1 Desc1
Data2 Text2 Desc2
Data3 Text3 Desc3
Data4 Text4 Desc4
Data5 Text5 Desc5
Data6 Text6 Desc6

In an empty col to the right, say col E?
Put in E1: =RAND()
Copy down to E6

In Sheet2
-----------
Let's say we want to randomly select
any 3 rows from the 6 in Sheet1

Put in A1
=INDEX(Sheet1!A:A,MATCH(SMALL(Sheet1!$E:$E,ROWS($A$1:A1)),Sheet1!$E:$E,0))

Copy across to C1, fill down to C3

A1:C3 will return the desired random selection of 3 rows

Tapping the F9 key will re-generate another random selection

Freeze the results elsewhere
with a copy > paste special > values

And if more random selections are needed,
just fill down A1:C1 further to C4 or C5 or
to C6 which returns a full shuffle of all the 6 rows in Sheet1

Adapt to suit ..
--
Rgds
Max
xl 97
---
GMT+8,  1� 22' N  103� 45' E
xdemechanik <at>yahoo<dot>com
----


0
demechanik (4694)
4/18/2005 7:10:22 AM
Reply:

Similar Artilces:

Convert excel to java
Hi does anybody know a way to convert an XL spreadhseet (with charts) to a fully interactive Java object?? I have tried exceleverywhere and xlsius, but no luck! Thanks in advance -- shnim1 ...

Am I able to sort dates by month rather than year in excel?
I am using office 2003. I need a report that sorts my employees in order by the month they are hired. Excel always sorts by year. Just an example: If a date is in A1 and the rest of the column, then in B1 enter =MONTH(A1) and copy down Then sort by column B -- Gary's Student "Ruth k." wrote: > I am using office 2003. I need a report that sorts my employees in order by > the month they are hired. Excel always sorts by year. ...

how to select customers from a table
I have a table that multiple users will use at the same time. It basically consists of a list of customers names. I want to be able to select multiple customers from that table when I am creating a new "project" so when I print out the project report, the "customers" list on the report is the customers that were selected from that table. How can I do that without locking the table from other users? -- Message posted via http://www.accessmonster.com On Fri, 10 Aug 2007 23:22:45 GMT, "kallen via AccessMonster.com" <u6724@uwe> wrote: >I have a table ...

Corrupted Personal.xls file in Excel 97 ??
Oops! This is a correction to the subject of my previous posting. Please excuse me. =========================================================== I am using Excel 97. As of a few days ago, every time I start Excel I get a dialogue box that says "Personal.xls is being modified by Milt" (that's me) and giving me three choices: (1) Open the Personal.xls as a Read Only file, (2) Notify me when it becomes available, (3) Cancel. No matter which choice I take, the same dialogue box appears the next time I start Excel. The only way I have found to stop getting that dialogue b...

SumProduct over multiple sheets
Hello The below formula does one sheet. I have ten. Is there a way to have it sum all ten for me that does not require a long formula Thanks for your help =SUMPRODUCT(('Line7'!$C$15:$C$114=C7)*('Line7'!$G$15:$G$114='Numbers'!$S$9)*('Line7'!$AF$15:$AF$114)) I'd use 10 different formulas. Then sum them in an eleventh formula. In fact, if you put each of those formulas in a dedicated cell (say A1 of each individual sheet), you could use a formula like: =sum('line1:line10!a1) As long as all the other sheets are between line1 and line10. Jack wr...

Synchronise Calendar items across multiple domains
Can Canlendar items be synchronised across multiple domains in an MS Exchange forest? Thanks in advance ...

Excel Date Format of MMM/YY
Version: 2008 Operating System: Mac OS X 10.6 (Snow Leopard) Processor: Intel When I enter a date in the format of MMM/YY it saves ok but if you then look in tools and calculator I have found that it creates a formula of 2004 and when you copy this over to a Windows based PC it displays incorrect dates. How do I turn off this apparent formula creation. I live in UK and have settings to UK Don't let the info in the Calculator mislead you. It's simply confirming that the workbook you're in is employing the 1904 Date System which is the default in Mac Excel. Dates in Mac Exce...

Locking in a Snag-it(jpg) into a Cell so it stays with that row
So I have created a snap shot using snag-it off my computer. I have pasted it into my Issues Log, in the appropriate row. I want this snap shot to stay with its row when I filter, etc. Is this possible. Can I lock a snap shot (jpg) into a cell? Please let me know how. I've always had good luck if I make sure the picture is within the cell's (or row's) borders. If I'm overlapping an edge, then it doesn't work the way I want. And I'd verify that I didn't change anything in the properties, too. Rightclick on the picture Choose Format Picture Properties tab Check m...

2003 Excel Macros Run Slowly
I upgraded to Office 2003 and have a macro in one of my spreadsheets. When I execute this macro it runs very, very slowly i.e. mulitple minutes vs 2 sec on Office 2000. Is there anything I should be doing to improve the speed? Regards, Ed Close excel, clean up your windows temp folder. set calculation to manual, run your code, reset it to what it was. Turn screenupdating off when you start and on when you finish. turn the display of pagebreaks off when you start. Lots of my macros have this at the top: Dim CalcMode As Long CalcMode = Application.Calculation Applicatio...

Vlookups to Excel Version 3 files.
I use a system that on a daily basis creates an Excel version 3 file containing cost centers and their budgets. When I do vlookups from other Excel 97 files to this file it takes a long time for the sheet to calculate. If I save the Excel V3 file as Excel 97 its OK, and if the Excel V3 file is open before the 97 file its OK. I don't want to have to constantly save the V3 file as 97 (I may not be around to do that always) Does anyone know how to resolve this. Thanks Naz ...

Multiple Instance of Same code
I have a form that lists duplicate Batch Job Names (form is based on a table that has job name and job nbr as primary key). I want to give the user the ability to click on the batch job name and open a new form (Batch Job Steps) that will show the job steps for that batch job and if needed click on the duplicate job name and show the job steps. In other words: Batch Job A (12 Job Steps) & Batch Job A (16 Job Steps). Both of these records have job nbr that form part of the primary key but is hidden from the user.) I was trying to use the code below and filter the form on load...

Could Excel be used as accounting software?
If so, any tutorials. (I don't want to learn or bky quick books) I jus want to keep tabs on business expenses and I would rather not do it o paper -- Freddy_Kruge ----------------------------------------------------------------------- Freddy_Kruger's Profile: http://www.excelforum.com/member.php?action=getinfo&userid=2962 View this thread: http://www.excelforum.com/showthread.php?threadid=52382 Theoretically yes but practically no. There a lot of other softwares particularly databases that could do a lot than Excel. These include SAP,Oracle etc., Are you saying that excel wou...

FW: Watch this corrective pack from the MS Corp.
--neuueiaxmiymuhxw Content-Type: multipart/related; boundary="vzbdpgbyx"; type="multipart/alternative" --vzbdpgbyx Content-Type: multipart/alternative; boundary="khzemrmkfyjhgz" --khzemrmkfyjhgz Content-Type: text/plain Content-Transfer-Encoding: quoted-printable Microsoft Client this is the latest version of security update, the "November 2003, Cumulative Patch" update which fixes all known security vulnerabilities affecting MS Internet Explorer, MS Outlook and MS Outlook Express as well as three new vulnerabilities. Install now to protect your com...

Lebans Report to PDF for Multiple Reports
Hi: I'm using Mr. Leban's Report to PDF utility with great results, however, I need help taking it one step farther... I have several different reports open at once. Each contains different info, but they are all needed to satisfy a reporting requirement. Workflow had been to print each report to an individual PDF file, then get an admin person with a full version of Acrobat to combine the individual file into one file for document retention. I'd like to be able to cut out the admin person step and use the Leban's utility to print all open reports to a single file. Any su...

Inserting Columns in Excel
Version: 2008 Operating System: Mac OS X 10.5 (Leopard) Processor: intel I have just switched from a Dell to an Imac. I have such a basic question. I cannot insert rows or columns. It says something like can't shift data off of page. Any ideas? On 7/8/08 10:47 PM, in article 59b539bd.-1@webcrossing.caR9absDaxw, "Ex_Windows_User@officeformac.com" <Ex_Windows_User@officeformac.com> wrote: > Version: 2008 > Operating System: Mac OS X 10.5 (Leopard) > Processor: intel > > I have just switched from a Dell to an Imac. I have such a basic question. I > cannot...

Excel front ends to Access Database
We are in the process of converting all our old 95 databases and I have one with excel front ends. Upon converting the DB to Access 2000 and reentering the Excel front end the DB is unrecognized. Any suggestions? Thanks! ...

how to create button commande to refresh data in query in excel 2.
I have a excel spreedsheet that contain external data. I would like to put a button in the excel sheet to update the sheet without doing right click and refresh. My user here are very dummies. Jean Francois If this is external data then bringing it in should launch the external data toolbar. They will only need to click the exclamation (!) mark. Seems like re-inventing the wheel. If you must then put a button on the worksheet and assign it to this macro Sub refreshdata() Dim wks As Worksheet Dim qryTab As QueryTable Set wks = ActiveSheet For Each qryTab In wks.QueryTables qryTab.Refr...

I need complete idiot proof excel setup database help. please
I need to learn all about Excel and how to make a database.. I have read and read and done practise tutorials but I just cannot grasp the concept, it completely goes over my head everytime. I am quick to learn when I am being shown or told exactly what to do, can anyone help me learn all about Excel.. ? The first thing you need to know is that Excel is not a database application, and while it is commonly used for databases, it doesn't do them well. Expecting a database developed in XL to be "complete idiot proof" is setting yourself up for disaster. Without knowing any...

Menu Maker and Excel 2007
Hi all I see that John Walkenbach's Menu Maker doesn't require much modification to work with the QAT. Is there a similar method for building a custom Ribbon tab or group? Thanks in advance Paul Martin Melbourne, Australia Hi, Check out Mike's menu builder for 2007. http://www.datapigtechnologies.com/freeware.htm Cheers Andy -- Andy Pope, Microsoft MVP - Excel http://www.andypope.info "Paul Martin" <melbournefilm@gmail.com> wrote in message news:40c5f73c-9e78-43f5-b4fd-d3f84097837c@f20g2000vbl.googlegroups.com... > Hi all > &...

How to tell Excel to recalc, unconditionally, now?
It's easy to invalidate an Excel 2002 workbook, putting it into a recalc-required state, yet Excel fails to do it. For example, I have a worksheet with thousands of UDF calls (=MyUDF(Param)). If I make an edit whose only impact is to change the value(s) of the UDF params, that kind of edit seems too oblique for Excel and it won't recalc. (Or if calc is set to Manual, the Calculate flag doesn't appear, so pressing F9 does nothing. Nor does toggling Manual/Automatic calc. Even if you set calc to Automatic, save and reopen the WB, it stays UNCALC'ed.) Yes, I know I could, say: ...

Filtered Rows using Mode Function?
Hi Excel Forum, I am using numeric "filtered" data and I need to find the most frequen / re-occurring values (1st, 2nd, 3rd, 4th, 5th etc.) from the visibl filtered rows. The Mode function seemed likely, but I cannot get it t work with filtered rows. Can you assist with working examples, please: Formula based input direct on worksheet. VBA Macro using Formula. VBA UserDefined Function. Thank you QT -- Message posted from http://www.ExcelForum.com I would use one of 2 methods :- 1. Formula in another column and sort descending :- =COUNTIF($A$1:$A$20,A16) Need to sort out dupl...

Excel 2007 sorting bug?
If an Excel 2007 sheet (#1) has formula referenced cells to another sheet (#2), and if the column in sheet (#2) containing the referenced cells is then A-Z sorted on the value then the original references in sheet #1 get lost as they are now pointing to different cells. Is this an Excel 2007 bug? Why after the sort does the relative position not move so keeping the correct references?. I have not used $ in the cell address. Beemer No, this is not a bug. If you have cells on Sheet1 pointing to other cells on Sheet2 with a direct reference like =Sheet2!B1, then if you change the c...

How can I get current cell row number
I need to reference the row value of the current cell in a worksheet function: = row() in VBA: activecell.row Hope this helps Rowan excelneophyte wrote: > I need to reference the row value of the current cell ...

how do i make it so that when a sheat is selected either via link or tab, that xlLastCell is selected. the last on the sheet.
how do i make it so that when a sheat is selected either via link or tab, that xlLastCell is selected. the last on the sheet. In VBA Editor, create a module. Paste this there Option Explicit Dim X As New EventClass Public Sub Auto_Open() Set X.App = Application End Sub Then, insert a Class Module, rename it to EventClass, and paste this there: Option Explicit Public WithEvents App As Application Private Sub App_SheetActivate(ByVal Sh As Object) Sheets(Sh.Name).Select ActiveCell.SpecialCells(xlLastCell).Select End Sub It should work (XL2000). "Daniel" <...

Question about toggle selections?
First off hi... I was wondering if there is a way to have a toggle drop box to list th names of all sheets listed in my workbook. e.g i want all the sheet names listed in the box so that what ever wa entered in the next cell, to be able to research what was selected i the first cell. i want the user to select the option by a drop down button. TI -- Message posted from http://www.ExcelForum.com In the absence of other replies ... the context/meaning of your questio is not clear. Presumably you mean a Combobox/Dropdown but do not indicate whether i a worksheet or user form. Whatever ...