devxlogo

Tip Bank

FileToBlob – Loading a file into a SQL Server’s BLOB

‘ Reusable routine that loads a file into a SQL Server’s BLOB.’ Requires Imports for System.Data and System.Data.SqlClient’ (It supports only tables with one key field.)” Example:’ FileToBlob(cn, “pub_info”, “logo”,

BlobToFile – Saving a BLOB field to a file

‘ Reusable routine that save a BLOB field to a file’ Requires Imports for System.Data and System.Data.Common’ Example: BlobToFile(dr, 2, “c:xxxx.bmp”)Sub BlobToFile(ByVal dr As IDataReader, ByVal fieldIndex As Integer, _

Write a Primary Key Class in CMP EJB

In the following example, the PurchaseOrderKey class implements a composite key for the PurchaseOrderEJB entity bean. The key is composed of two fields, productModel and vendorId, whose names must match

Override Built-in Keywords

You can override some of the built-in VB keywords with your own version of the function. For instance, FileDateTime is a handy built-in function in VB, but it suffers from