3

I know that in windows 8, certain applications have a notification on the lock screen, and some fingerprint readers can add messages to the logon screen in windows 7 and older machines. Is it possible for a program to display a message on the logon screen for Windows 7 using c#? If so, can that message be dynamic?

Shiva
  • 20,575
  • 14
  • 82
  • 112
Often Right
  • 427
  • 1
  • 9
  • 22

1 Answers1

2

Yes it is possible to add/changes the logon screen message. It involves updating the legalnotiecaption and legalnoticetext values in the registry.

See this article for a detailed walkthrough: Display a Startup Message Box in Windows 8 It will work for Windows 7 also, since we are modifying the registry keys (which haven't changed between windows versions).

enter image description here

As for whether the message can be dynamic, I am not sure, since it comes from the registry. I guess you could write a C# app that stores the current / existing values for those 2 registry entries, then updates them at startup. (Don't forget to call Close() on the RegistryKey object in your C# code :)

Also, if you are "afraid" of modifying the registry entries directly, you can make the same changes by updating 2 options in the Local Security Policy. Behind the scenes, the 2 updates eventually update the same 2 registry keys - legalnotiecaption and legalnoticetext.

See: Create a logon message for users in Windows 7 | 8

  • Run secpol.msc and hit Enter to open the Local Security Policy
  • Expand Local Policies > Select Security options.
  • In the RHS pane, double click Interactive logon: Message title for users attempting to log on. Change and save it.
  • In the RHS pane, double click Interactive logon: Message text for users attempting to log on. Change and save it.
Community
  • 1
  • 1
Shiva
  • 20,575
  • 14
  • 82
  • 112
  • @N.Soong from the VERY FIRST line in the article explaining it *"In this article we explain how to display a startup message box in Windows 8. This same functionality is available in Windows 7."* – Scott Chamberlain Feb 16 '14 at 03:33
  • @N.Soong It should work for both versions. I also updated the post to use Local Security Policy to achieve the same effect. Behind the scenes, this approach also modifies the same 2 registry key values. – Shiva Feb 16 '14 at 03:40
  • The idea I had was to have a countdown timer on the logon screen. As this is constantly changing, will this still work? – Often Right Feb 16 '14 at 22:18