Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
David M Fritzke
 
Posts: n/a
Default Pick a Random name from a list.

I am working on a Free Give Away of some products. Our systems give me a
list of individuals who we have had contact which are then placed in excel.
We would like to pick a weekly winner and would prefer not to throw darts at
my screen. Any Ideas?
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Jerry W. Lewis
 
Posts: n/a
Default Pick a Random name from a list.

If there are 1700 names in column A in cells A1:A1700, then
=OFFSET(A1,INT(1700*RAND()),0)
should do the job.

Jerry

"David M Fritzke" wrote:

I am working on a Free Give Away of some products. Our systems give me a
list of individuals who we have had contact which are then placed in excel.
We would like to pick a weekly winner and would prefer not to throw darts at
my screen. Any Ideas?

  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
David M Fritzke
 
Posts: n/a
Default Pick a Random name from a list.

Thanks I will give it a Try!

"Jerry W. Lewis" wrote:

If there are 1700 names in column A in cells A1:A1700, then
=OFFSET(A1,INT(1700*RAND()),0)
should do the job.

Jerry

"David M Fritzke" wrote:

I am working on a Free Give Away of some products. Our systems give me a
list of individuals who we have had contact which are then placed in excel.
We would like to pick a weekly winner and would prefer not to throw darts at
my screen. Any Ideas?

  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 2
Default Pick a Random name from a list.

Is there a way to show just the random name graphically and make this
automatic for a daily drawing that takes place at a set time daily.

"Jerry W. Lewis" wrote:

If there are 1700 names in column A in cells A1:A1700, then
=OFFSET(A1,INT(1700*RAND()),0)
should do the job.

Jerry

"David M Fritzke" wrote:

I am working on a Free Give Away of some products. Our systems give me a
list of individuals who we have had contact which are then placed in excel.
We would like to pick a weekly winner and would prefer not to throw darts at
my screen. Any Ideas?

  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 296
Default Pick a Random name from a list.

Depends what you mean by graphically.

Adapting Chip Pearson's VBA Timer code at:
http://www.cpearson.com/excel/ontime.htm

and using Jerry's code, you could make the StartTimer sub (see below)
the subject of a Workbook open event, or just run it manually. A
message box will pop up at 11 a.m with the name of the winner.

If you want some fancy graphics then you could design a userform
containing a label, which gets populated with the name of the winner.
You could show this form at the appropriate time instead of the
Message box.

HTH


Public RunWhen As Double
Public Const cRunWhat = "Winner"

Sub StartTimer()
RunWhen = TimeSerial(11,00,00)
Application.OnTime earliesttime:=RunWhen, procedu=cRunWhat,
schedule:=True
End Sub

Sub Winner()
Dim stWinner As String
StartTimer
stWinner = Range("A1").Offset(Rnd() * 1700, 0)
MsgBox "Today's winner is : " & stWinner
End Sub




On Thu, 24 Aug 2006 09:16:02 -0700, Stafford
wrote:

Is there a way to show just the random name graphically and make this
automatic for a daily drawing that takes place at a set time daily.

"Jerry W. Lewis" wrote:

If there are 1700 names in column A in cells A1:A1700, then
=OFFSET(A1,INT(1700*RAND()),0)
should do the job.

Jerry

"David M Fritzke" wrote:

I am working on a Free Give Away of some products. Our systems give me a
list of individuals who we have had contact which are then placed in excel.
We would like to pick a weekly winner and would prefer not to throw darts at
my screen. Any Ideas?


__
Richard Buttrey
Grappenhall, Cheshire, UK
__________________________


  #6   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 2
Default Pick a Random name from a list.

Thanks. I'll see if I can get it to work.

"Richard Buttrey" wrote:

Depends what you mean by graphically.

Adapting Chip Pearson's VBA Timer code at:
http://www.cpearson.com/excel/ontime.htm

and using Jerry's code, you could make the StartTimer sub (see below)
the subject of a Workbook open event, or just run it manually. A
message box will pop up at 11 a.m with the name of the winner.

If you want some fancy graphics then you could design a userform
containing a label, which gets populated with the name of the winner.
You could show this form at the appropriate time instead of the
Message box.

HTH


Public RunWhen As Double
Public Const cRunWhat = "Winner"

Sub StartTimer()
RunWhen = TimeSerial(11,00,00)
Application.OnTime earliesttime:=RunWhen, procedu=cRunWhat,
schedule:=True
End Sub

Sub Winner()
Dim stWinner As String
StartTimer
stWinner = Range("A1").Offset(Rnd() * 1700, 0)
MsgBox "Today's winner is : " & stWinner
End Sub




On Thu, 24 Aug 2006 09:16:02 -0700, Stafford
wrote:

Is there a way to show just the random name graphically and make this
automatic for a daily drawing that takes place at a set time daily.

"Jerry W. Lewis" wrote:

If there are 1700 names in column A in cells A1:A1700, then
=OFFSET(A1,INT(1700*RAND()),0)
should do the job.

Jerry

"David M Fritzke" wrote:

I am working on a Free Give Away of some products. Our systems give me a
list of individuals who we have had contact which are then placed in excel.
We would like to pick a weekly winner and would prefer not to throw darts at
my screen. Any Ideas?


__
Richard Buttrey
Grappenhall, Cheshire, UK
__________________________

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Random List Generation carl Excel Worksheet Functions 4 May 23rd 06 02:18 PM
Random items from a list? arcngel Excel Discussion (Misc queries) 3 September 8th 05 06:04 PM
Create a pick list to use to go to a text cell in Excel Pegita Excel Worksheet Functions 1 June 23rd 05 07:24 PM
Calculate Value of Cell From Pick List Choice Buz Excel Discussion (Misc queries) 1 April 5th 05 08:52 PM
Random list (1-45) without repeating numbers? Hayes Excel Worksheet Functions 1 November 21st 04 10:01 PM


All times are GMT +1. The time now is 05:18 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"