0

I would like to set up a news-reel on a form to update users on forthcoming changes etc can someone point me in the right direction.

Erik A
  • 31,639
  • 12
  • 42
  • 67
A Hughes
  • 235
  • 1
  • 2
  • 15
  • 2
    What do you mean? A textbox that gets updated while someone is working? Or just a textbox with infos? Or a continuous form? Be a bit more specific about what you consider to be a newsreel. – Roland Jul 05 '14 at 17:25
  • A textbox with infos (could be multiple items so it would nees to scroll). I would set the news each day. – A Hughes Jul 05 '14 at 18:09
  • @AHughes What are business rules? Those business rules about min and max number of news showed simultaneously can be enforced via SQL view. Example: "always show a minimum of last three news or all news from pass 12 hours". In the other hand, timiming business rules must be enforced in form whit a timer calling this SQL view in every Tick. Example: "Al news should be displayed within ten minutes of publication" So, you will set timer interval to 60x10x1000=600.000 ms and refreshing your texbox on each tick event – Horaciux Jul 06 '14 at 00:30

1 Answers1

0

I would recommend using a continuous (sub)form bound to a table News(ID,Timestamp,Info) and sort Timestamp DESC so the last news will always show up topmost. You can also put a query between table and form and use the TOP keyword to extract only the latest N infos. On the other hand you can set a filter on the form to display all news with a datetime higher than DATE() - numDays. There are, as you see, numerous ways depending on your intention.

You can bind the reloading of this (sub)form to the ON_CURRENT event of the parent form so it gets updated each time someone does something in the parent form. If the parent form is never reloaded or flipped but you still want to update on a regular basis during the day you can use the Timer approach as @Horaciux has mentioned.

Roland
  • 946
  • 8
  • 20
  • You can, of course, simply use the textbox approach and bind it to a one-column table, updating it every day manually. – Roland Jul 06 '14 at 10:42
  • If the message is longer than the text box how would it automatically scroll to show the user the full message? – A Hughes Jul 06 '14 at 20:11
  • http://stackoverflow.com/questions/5275249/how-do-i-configure-a-textbox-control-to-automatically-resize-itself-vertically-w – Roland Jul 06 '14 at 20:39