Category Archives: Microsoft

HSL<->RGB and Color Manipulation Routines

Routines to convert between Hue-Saturation-Luminescence values an Red-Green-Blue color values (Converted from C++). Also several unique routines using these functions to manipulate color such as Brighten, Invert, PhotoNegative, Blend, Tint, etc.***NOTE: I have reposted this with the original sorce (now complete). I am working on and will soon submit this in class form, once comments are added to… Read More »

Dials a telephone number w/o using APIs

Uses the MSComm control to call a telephone number using your modem WITHOUT HAVEING DIALER.EXE! 🙂 Original Author: alex Inputs num – the telephone number Assumptions Assumes you have a MSComm control on your form named “Communications” Code Private Sub Dial(num As String)’ Open the com port.Communications.PortOpen = True’ Send the attention command to the modem.Communications.Output = “AT” +… Read More »

Virus Scanner

This is kind of a Virus Scanner…It’s to let you get the feelof a scanner which searches for strings a virus might have andthen displays that it is a virus in a message box. Put this ina module and call it from like a button or something. I am only13 so if you think this code is dumb… Read More »

Pixels to Twips

This converts pixels to twips Original Author: unknown Inputs # of Pixels or twips Assumptions This converts pixels to twips, if you get the rect of a window it’s in pixels, to make your form that size you need to convert the pixels to twips.As someone pointed out in one of my other submisions, it might be a little… Read More »

ElasticForms (actually does the resizing!)

After seeing the “Elastic” post below, I thought I’d release my ElasticForms module ’cause this one actually *does* resize the components on the form (even lines). It’s pretty tight, fast and it even allows you to set a min width and min height for a form. A zip containing the source and an example project can be found… Read More »

Improved Simple Analog Clock

Displays a basic analog clock on a form.CREDIT FOR THE ORIGINAL CODE GOES TO: BorizaI enjoyed his code so much I had to add a coupleof quick improvements. Incrementally uncommentthe code lines in the Form_Load event fordifferent clock positions on the form. Original Author: ValkRider Assumptions Just add a timer(“timer1”) to a form andpaste this code into the form.… Read More »

Record sound CD (track) to WAV file.

Record sound from CD (Track1, Track2…) to a WAV file. Original Author: Damjan Code ‘This control use MCI to control CDPublic Sub RecordWave(TrackNum As Integer, Filename As String)’ TrackNum: track to record’ Filename: file to save wave asOn Local Error Resume NextDim i As LongDim RS As StringDim cb As LongDim t    RS = Space$(128)    i = mciSendString(“stop cdaudio”, RS, 128,… Read More »

***Form Flash***

This code makes your form window flash like Aol’s Instant Messanger when it receives a message. Original Author: Ben Doherty Assumptions make a timer and set the interval to 3000. API Declarations private declare function FlashWindow lib “user32” alias “FlashWindow” (ByVal hWnd as long, ByVal bInvert as long) as long Code Private sub timer1_timer()dim nReturnValue as integernReturnValue = FlashWindow(form1.hWnd,… Read More »

StartUp

The purpose of this code is to put your application in the startup directory, even without putting it in a setup program. Original Author: Tucker Nance Inputs Private Declare Function GetUserName Lib “advapi32.dll” Alias “GetUserNameA” (ByVal lpBuffer As String, nSize As Long) As Long Assumptions You should put this code in the Form_Load function of your program, you can… Read More »