|
How to recover database from suspect mode?
|
Total Hit (26553) |
Sometime your database may go into suspect mode. A database can be marked suspect for one of the following reasons (this is from SQL Server Books Online):
«code LangId=0»If one or more database files are not available.
If the entire database is not available.
If one or more database files are
....Read More |
Rating
|
|
|
|
C# to VB.net Converter
|
Total Hit (1312) |
The C# to VB.NET Translation tool is not perfect. However, it is the best C# to VB.NET translation tool that I have come across. It's very easy to use. Simply copy and paste your C# code into the textbox and hit the 'Translate' button. Currently, the translator does not handle <script> tags or any o
....Read More |
Rating
|
|
|
Getting StdPicture's Width and Height properties in Pixels
|
Total Hit (5117) |
In general, Visual Basic doesn't provide a way to determine the size of a bitmap loaded into a PictureBox control. But you can derive this information if you set the control's AutoSize property to True and then read the control's ScaleWidth and ScaleHeight properties. If you don't want to resize a v
....Read More |
Rating
|
|
|
Finding SQL Server Object Name from PageNumber
|
Total Hit (6655) |
Most of time when sql server throw an error will tell you object Id or PageNumber.
This article will show you how to find which object caused the error.
«b»Step-By-Step Example«/b»
Lets say you got the folloing error from SQL Server
«b»Error«/b»
«font color=red»Error: 7105, Severity:
....Read More |
Rating
|
|
|
How to clear all controls of a winform or user control?
|
Total Hit (4472) |
Here is the small code snippet to clear most of all controls on your form. This code also take care of containers like group box, panel ... etc.
«code LangId=2»
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
ClearControls(Me.Contr
....Read More |
Rating
|
|
|
UDF : ParseArray - return table from CSV
|
Total Hit (3585) |
Sometimes we may need to store values in one field using some sort of seperating character. For example if you want to store multiple values in one field instead of normalizing your table and creating a whole new table to store multiple records. This articles will show you how you can create a UDF w
....Read More |
Rating
|
|
|
|
Shrinking transaction log file on sql server 7.0
|
Total Hit (1992) |
Many times when I do bult insert/delete operation my transaction log grows very fast and I use this scipt to shrink it. This simple scrip will show you how to shrink transaction log file in SQL Server 7.0 when your DBCC SHRINKFILE command wont work. In most cases DBCC SHRINKFILE(<log filename>,<new
....Read More |
Rating
|
|
|
Must see >> MZ-Tools 3.0 - Free (All-in-one VB 6.0/5.0/VBA Addin)
|
Total Hit (1452) |
MZ-Tools 3.0 is a freeware 'all-in-one' add-in for Visual Basic 6.0, Visual Basic 5.0 and the Visual Basic For Applications editor (provided by a VBA-enabled application such as the ones of Office 2000 and higher) which adds several productivity features to the IDE. It provides a main menu, a toolba
....Read More |
Rating
|
|
|
|
Convert VB.net Code to C#
|
Total Hit (1417) |
This utility will allow you to convert your VB.NET code to its equivalent in C#.
|
Rating
|
|
|
|
|
Drag and Drop files/folders from explorer and display in listbox
|
Total Hit (4235) |
This code will show you how simple it is to get file/folder list dragged from explorer.
«b»Step-By-Step Example«/b»
- Create a Windows Application
- Add one ListBox control on the form
- Add the following code in form1
- Run the project and try to drag and drop some files into listbox from
....Read More |
Rating
|
|
|
|
|
|
Guitar simulation using MIDI APIs
|
Total Hit (5950) |
«b»Step-By-Step Example«/b»
- Create a standard exe project
- Add one listbox, combobox and 2 command button controls
- Add one class module and rename it to clsMIDI
- Add the following code in form1
«b»Form1.frm«/b»
«code LangId=1»Dim objMIDI As New clsMIDI
Private Enum enumInstruments
....Read More |
Rating
|
|
|
Tip: How to display all environment variables
|
Total Hit (2506) |
«code LangId=1»Private Declare Function GetEnvironmentStrings Lib "kernel32" Alias "GetEnvironmentStringsA" () As Long
Private Declare Function FreeEnvironmentStrings Lib "kernel32" Alias "FreeEnvironmentStringsA" (ByVal lpsz As String) As Long
Private Declare Function lstrlen Lib "kernel32" Alias
....Read More |
Rating
|
|
|
How to change owner of DTS Package
|
Total Hit (2811) |
Here is an example to change ownership of a DTS Package of SQL Server. You can use undocumented stored procedure msdb.dbo.sp_reassign_dtspackageowner to change ownership. This stored proc requires 3 parameters. First parameter is @name which is name of package. Second parameter is @id which unique I
....Read More |
Rating
|
|
|
How to move, copy, and back up full-text catalog folders and files
|
Total Hit (1575) |
Full-text catalogs and indexes are not stored in a SQL Server database. Full-text catalogs and indexes are stored in separate files that the Microsoft Search service manages. The full-text catalog files are not recovered during a Microsoft SQL Server recovery. Additionally, you cannot use the Transa
....Read More |
Rating
|
|
|
How to start/stop and enum services using ADSI
|
Total Hit (4186) |
This article will show you sample code to use ADSI to manage services.
«b»Step-By-Step Example«/b»
- Create a new standard exe project
- Add reference to "Active Ds Type Library" (Project->Add Reference)
- Add windows common control 6.0 (Project->Controls)
- Add one listview, five command b
....Read More |
Rating
|
|
|
|
Print Dialogbox without using Common Dialogbox ActiveX control
|
Total Hit (4970) |
This code will show you use of PrintDialog API to show print dialogbox.
«b»Step-By-Step Example«/b»
- Create a standard exe project
- Add one class module
- Rename it to clsPrnDlg
- Add one command button on form1
- Place the following code in form1
«code LangId=1»Private Sub Command1_C
....Read More |
Rating
|
|
|
The Open Source Development Environment for .NET
|
Total Hit (1411) |
#develop (short for SharpDevelop) is a free IDE for C# and VB.NET projects on Microsoft's .NET platform. It is open-source (GPL), and you can download both sourcecode and executables from this site. In addition, you can find the latest information and changes on #develop, as well as get in touch wit
....Read More |
Rating
|
|
|
|
|
|
Connection strings for various OLEDB Data Providers
|
Total Hit (2721) |
OLE DB Providers for Active Directory Service, Advantage, AS/400 (from IBM), AS/400 and VSAM (from Microsoft), Commerce Server, DB2, DTS Packages, Exchange, Excel, Internet Publishing, Index Server, Microsoft Jet, Microsoft Project, MySQL, ODBC Databases, OLAP Services, Oracle (from Microsoft), Orac
....Read More |
Rating
|
|