devxlogo

Tip Bank

Print3D – Drawing a text with 3D effect

‘ Display a text with 3D effect” g: a Graphics object’ text: the text to be displayed’ coords: the Point with the X and Y coordinates’ col: the text color’

Ask a Yes/no question and return a Boolean

‘ Ask a Yes/no question’ returns True if the user replies “Yes”‘ Example: MessageBox.Show(AskYesOrNo(“Do you like me?”, “ME”, True))Function AskYesOrNo(ByVal text As String, ByVal title As String, _ ByVal defaultAnswer

ChangeDriveIcon – Changing the icon of a drive

‘ Change the icon of a drive’ Example: ChangeDriveIcon(“d”, “c:myicon.ico”)Sub ChangeDriveIcon(ByVal driveLetter As String, ByVal icoPath As String) ‘ create the parent key Dim regKey As Microsoft.Win32.RegistryKey = _ Microsoft.Win32.Registry.LocalMachine.CreateSubKey(

Execute a SQL Server DTS Package Remotely

You can easily execute a SQL Server 7.0 Data Transformation Services (DTS) package from VB remotely: Create a DTS package. It can be an import from Excel into SQL Server.