Category Archives: Visual Basic 6 (VB6)

Make your own CD-Player!

Fixed it! This is the source that will let you make your own CD Player! It uses the Media Control Interface (MCI) via API to play a audio cd. [NOTE: For this class to work on a form you must reference the class eg. (Set Snd = New CDAudio. I already have prepared it in the included zip.)… Read More »

formatcurrency

format a text field into a $ currency field. Original Author: Vikramjit Singh Inputs text box name Assumptions Call teh module by passing any text box name that you want to have as a currency text box. Returns formatted value in $ API Declarations ‘put as many text boxes as you want…say text1‘call the class by using the following… Read More »

DBGrid Sort

It is nice technique for dbgrid sorting.Youcan sort Dbgrid Columns by clicking on the grid column headerin two ways ascending or descending. Original Author: Adam Abas Returns Sorted Records in dbgrid. Side Effects No Idea, API Declarations Code Option ExplicitDim st As Boolean***********************Private Sub DBGrid1_HeadClick(ByVal ColIndex As Integer)’Dbgrid Columns sort by clicking the grid header in two way ascending… Read More »

2 MINUTE WEB BROWSER!!!

This is similar to the 15 minute web browser, but is MUCH easier and has many more options!!! Original Author: Matt Evans API Declarations Code Step 1) Start up a project in VB… Make a new oneStep 2) Goto ‘Add Form’, Double-Click on Web BrowserStep 3) Goto Project1 Properties… And change the startup form to wWebBrowser1Step 4) Remove form1… Read More »

***UPDATED*** Window SPY

***UPDATED*** Gets tons of information on the window your mouse is over. Original Author: Matt Evans API Declarations Public Declare Function GetCursorPos Lib “user32” (lpPoint As POINTAPI) As LongPublic Declare Function GetWindowText Lib “user32” Alias “GetWindowTextA” (ByVal hwnd As Long, ByVal lpString As String, ByVal cch As Long) As LongPublic Declare Function GetModuleFileName Lib “kernel32” Alias “GetModuleFileNameA” (ByVal hModule… Read More »

EZ – .ini

Access .ini files in the blink of an eye. Use one line of your input to quickly retrive .ini values. With the same one line of code write to your .ini file. If you have any improvements on this code, E-Mail me at “karatebob@hotmail.com”. Original Author: Frank Joseph Mattia Assumptions When you call this in your code, this is… Read More »

View a playing card using VBCARDS.OCX

Simple code shows how to display any playing card image using the VBCARDS.OCX. Original Author: Patrick K. Bigley Assumptions Create a form (Form1)Create a command button control (Button1)Create an image control (Image1)Create a label control (Label1)Create a VBCARDS control (Deck1)A free copy of the VBCARDS OCX control can be downloadedat http://bargainbd.com/opusopus/vbcards.htmorhttp://www.geocities.com:80/SiliconValley/Grid/7284/cardocx1.zipDon’t crowd the screen with the controls, spacethem neatly… Read More »

Create New Controls At Runtime !

This code will allow you to create a new instance of a controlat runtime !Imagine. When your app is RUNNING you can create a new command buttonor a textbox on the fly ! The code they didn’t want you to know 😉 Original Author: Marc A. Foumberg API Declarations NONE Code ‘Create a new project.’Add a command button.’Name the… Read More »

DBGrid Dropdown Listbox

Ever wondered what the button_click event was for in a DBGrid? Well, this is it! You have to populate a listbox control and display that with the selection information. This will simulate a dropdown box within the dbgrid. This is an excelent way to input specific information into the dbgrid. Original Author: Jason J. Martin Returns Nont Side Effects… Read More »

Set ACL using low-level access control functions

This module provides a function that uses the Windows NT low-level access control functions to set the access rights on a folder (directory). The High-level access control functions (GetNamedSecurityInfo etc) do not function properly. They merge all ACEs for each SID. MS only acknowledges one of the four functions as malfunctioning, in fact they all are not suited… Read More »