
Since 1998, DevX has helped people start businesses, build websites, and provide enterprise technology to people globally. Interviewing the likes of Microsoft’s co-founder, Steve Ballmer, the publication brings comprehensive, reliable, and accessible insights to the Internet.
Private Declare Function FindFirstFile Lib “kernel32” Alias “FindFirstFileA” _ (ByVal lpFileName As String, lpFindFileData As WIN32_FIND_DATA) As LongPrivate Declare Function FindNextFile Lib “kernel32” Alias “FindNextFileA” _ (ByVal hFindFile As Long,
Thanks to the undocumented TlbInf32 library you can emulate the VB6 CallByName() function in VB5 too. First, add a reference to the “TypeLib Information” type library in your project. This
ADODataNav is an activex data navigational control disigned in and for Visual Basic that you can connect to an ADO MSData control giving you two usefull toolbars for navigation and
‘ build a list of all the individual words in a string” returns a collection that contains all the unique words.’ The key for each item is the word itself’
‘ evaluate the area of a triangle’ given its three sidesFunction TriangleArea(side1 As Double, side2 As Double, _ side3 As Double) As Double ‘ this function uses the Heron formula
‘ Returns an array with the first N prime numbers” Note: you can easily convert this routine to VB4 and VB5 by’ returning the result array through an argument instead
‘ Return True if a character belongs to a given catagory” CHARTYPE can be the sum of one or more of the following values’ 1 = Uppercase alpha char [A-Z]’
‘ convert from Celsius to Fahrenheit degreesFunction CelsiusToFahrenheit(ByVal value As Single) As Single CelsiusToFahrenheit = value * 1.8 + 32End Function’ convert from Fahrenheit to Celsius degreesFunction FahrenheitToCelsius(ByVal value As
Introduction As you have probably heard thousands oftimes, XML is a core technology in .NET. XML is a cornerstone of web services and ADO.NET recordsets (now calleddatasets) are internally stored
Private Declare Function LoadIconByID Lib “user32” Alias “LoadIconA” (ByVal _ hInstance As Long, ByVal lpIconName As Long) As LongPrivate Declare Function DrawIcon Lib “user32” (ByVal hDC As Long, _ ByVal
Type BITMAP bmType As Long bmWidth As Long bmHeight As Long bmWidthBytes As Long bmPlanes As Integer bmBitsPixel As Integer bmBits As LongEnd TypePrivate Declare Function GetObjectAPI Lib “gdi32” Alias
Private Type PICTDESC cbSize As Long pictType As Long hIcon As Long hPal As LongEnd Type Private Declare Function OleCreatePictureIndirect Lib “olepro32.dll” _ (lpPictDesc As PICTDESC, riid As Any, ByVal
‘ Move and resize a ProgressBar control so that it fits inside’ a StatusBar’s Panel.” The last argument is the panel index (one-based).Sub MoveProgressBarIntoPanel(pb As ProgressBar, sb As StatusBar, _
Private Type RECT Left As Long Top As Long Right As Long Bottom As LongEnd TypePrivate Type PICTDESC cbSize As Long pictType As Long hIcon As Long hPal As LongEnd
Private Declare Function LoadStandardIcon Lib “user32” Alias “LoadIconA” (ByVal _ hInstance As Long, ByVal lIconID As Long) As LongEnum SystemIconConstants IDI_Application = 32512 IDI_Hand = 32513 IDI_Question = 32514 IDI_Exclamation
You probably use the Format function to format date, for example: ? Format(Now, “mm/dd/yyyy”) ‘ => 08/01/2001 ? Format(Now, “mm+dd+yyyy”) ‘ => 08+01+2001 It seems that this is everything you
Temporary objects, or unnamed objects, are created as a result of expressions requiring a temporary object or when the user instantiates them explicitly. If the temporary object is not bound
Suppose you need to convert a string containing a hexadecimal value to int. Although you can use a std::stringstream object for this purpose, it’s worth noting that good old C
std::istream and std::ifstream objects define the eof() member function which returns true when the stream object has reached the end of a file. Note that at least one read operation
Standard C and C++ don’t allow comments to be nested. Thus, the following code snippet is ill-formed because it has one /**/ comment nested within another pair of comments: /*int
All implementations impose a limit on the number of files that a process can open simultaneously. This limit depends on various factors such as the process’ privileges, the number of
This can be achieved in java by throwing an exception from your Constructor. Since Constructors cannot return a value, this is the only way you can achieve error handling. Class
A direct method or class that will allow you to read NT system properties does not exist. However, it can be done as follows: Write a simple batch command file
A previous tip explained how to change the appearance of the ‘list selection’ cells of a JComboBox by setting the attributes of the JComboBox object’s ListCellRenderer.However, the ListCellRenderer controls the
The java.util.Map interface is the root interface of the map hierarchy. Interestingly, it doesn’t extend the familiar java.util.Collection interface. It facilitates storage, retrieval, and manipulation of key-value pairs.The popular implementations
In Win32 we create many objects – Windows, File, Threads, process,Semaphore, Event, Pen, Brush, etc. Some of the above are kernal objects while others are not. This tip is an
Static inner classes are pretty simple in concept and implementation.Basically, you define a static class inside your primary class: public class Foo // …. public static class Test public static
Dim rs As New ADODB.Recordset Dim vCount() As Variant Dim lCount As Long rs.Open
To list the fieldnames of a recordset in runtime, break the code in the procedure after the recordset has been initialized and enter the following lines into the debug window.
Sometimes you have a stored procedure that takes 2 to 5 minutes to execute. Applications that lock up frequently frustrate users and waste their time and resources. The ADO asynchrous











