Jump to content
Xtreme .Net Talk

Recommended Posts

Posted

Hi,

 

I have migrated from Win ME into Win XP (therefore VS 6 to VS.NET 2003 Pro.) and need some help. I only have knowledge in VB and nothing else - please help!

 

For a screensaver programme in VS 6, I had the following:

 

Public Const SPI_SCREENSAVERRUNNING = 97

 

Public Declare Function SystemParametersInfo Lib "user32" Alias "SystemParametersInfoA" (ByVal uAction As Long, ByVal uParam As Long, ByRef lpvParam As Any, ByVal fuWinIni As Long) As Long

'-------------------------------------------------------

'ENABLE/DISABLE CODE

'-------------------------------------------------------

'ENABLE:

'Call SystemParametersInfo(SPI_SCREENSAVERRUNNING, True, lPrev, 0)

'DISABLE:

'Call SystemParametersInfo(SPI_SCREENSAVERRUNNING, False, lPrev, 0)

 

In Win ME, the enable and disable code worked fine - keys like CTRL+ALT+DEL were blocked out, however, in XP, the code doesn't work! What do I need to change?

 

 

Mike

Posted

Someone correct me if I'm wrong but you should not be using an API call in .NET. You should use the Framework to provide you with what you want.

 

I haven't looked into this but there must be ready made classes provided by .NET to allow such programming

My website
  • Leaders
Posted
there are many times you may still need to use Api's in .net , but providing help for disabling CTRL+ALT+DEL isn't really a policy of this forum ( things like that could be used for malicious purposes )

  • Administrators
Posted

Password protected screensavers don't really work under XP (or any NT based OS) - when the screensaver kicks in it simply locks the workstation - they will just need to provide their name and password to unlock.

 

Not sure if you can intercept CTRL+ALT+DEL under NT anyway (or at least not without creating very low level kernel handlers).

Posting Guidelines FAQ Post Formatting

 

Intellectuals solve problems; geniuses prevent them.

-- Albert Einstein

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...