Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 2
Default Is there a way to get excel to sort data every 30 seconds

Is there a way to get excel to sort data every 30 seconds or contiously. I am
getting a data feed from bloomberg and would like to see the data sort every
30 seconds. Is there an easy way to do this automaticly?
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 11,058
Default Is there a way to get excel to sort data every 30 seconds

This is just an example that you can adapt to suit your specific worksheet.
After installing the macros, run StartTimer. It will re-sort column A every
30 seconds. To stop this repeated re-sorting, just run StopTimer:

Public whn As Double
Public Const T = 30
Sub SortA()
Columns("A:A").Sort Key1:=Range("A1"), Order1:=xlAscending, Header:=xlNo
StartTimer
End Sub
Sub StartTimer()
whn = Now + TimeSerial(0, 0, T)
Application.OnTime EarliestTime:=whn, Procedu="SortA", Schedule:=True
End Sub
Sub StopTimer()
On Error Resume Next
Application.OnTime EarliestTime:=whn, Procedu="SortA", Schedule:=False
End Sub


Macros are very easy to install and use:

1. ALT-F11 brings up the VBE window
2. ALT-I
ALT-M opens a fresh module
3. paste the stuff in and close the VBE window

If you save the workbook, the macro will be saved with it.

To use the macro from the normal Excel window:

1. ALT-F8
2. Select the macro
3. Touch Run



To remove the macro:

1. bring up the VBE window as above
2. clear the code out
3. close the VBE window

To learn more about macros in general, see:

http://www.mvps.org/dmcritchie/excel/getstarted.htm


--
Gary''s Student - gsnu200822


"BetaHedger" wrote:

Is there a way to get excel to sort data every 30 seconds or contiously. I am
getting a data feed from bloomberg and would like to see the data sort every
30 seconds. Is there an easy way to do this automaticly?

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
How do I change a minutes and seconds as a 2400 time to seconds? NickBrown419 Excel Worksheet Functions 1 August 10th 08 09:12 PM
Converting Julian Seconds with a macro to replace old seconds data Keldair Excel Discussion (Misc queries) 2 February 18th 06 12:09 AM
How do i refresh external data import in excel in seconds Bala New Users to Excel 2 December 29th 05 05:12 AM
Convert "Time Interval" in "hours : minutes : seconds" to seconds Ianukotnorth New Users to Excel 7 May 8th 05 08:11 PM
Convert seconds to minutes and seconds in excel anonymous Excel Worksheet Functions 3 December 25th 04 08:38 PM


All times are GMT +1. The time now is 10:47 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"