Atlanta Custom Software Development 

 
   Search        Code/Page
 

User Login
Email

Password

 

Forgot the Password?
Services
» Web Development
» Maintenance
» Data Integration/BI
» Information Management
Programming
VB VB (1648)
VB.net VB.net (736)
C# C# (15)
ASP.net ASP.net (779)
ASP ASP (41)
VC++ VC++ (25)
PHP PHP (0)
JAVA JAVA (4)
JScript JScript (5)
  Database
» SQL Server (708)
» ORACLE (5)
» MySQL (0)
» DB2 (0)
Automation
» C/C++/ASM (11)
» Microcontroller (1)
» Circuit Design (0)
OS/Networking
» Networking (5)
» Unix/Linux (1)
» WinNT/2k/2003 (8)
Graphics
» Flash (0)
» Maya (0)
» 3D max (0)
» Photoshop (0)
Links
» ASP.net (2)
» PC Interfacing (1)
» Networking (4)
» SQL Server (4)
» VB (23)
» VB.net (4)
» VC (3)
» HTML/CSS/JavaScript (10)
Tools
» Regular Expr Tester
» Free Tools

(Page 61 of 133) 3985 Result(s) found 

 

AddBackslash - Append a backslash to a path if needed
Total Hit (4089) «Code LangId=2» ' Append a backslash (or any character) at the end of a path ' if it isn't there already Function AddBackslash(ByVal Path As String, Optional ByVal ch As Char = "\"c) _ As String If Not Path.EndsWith(ch) Then AddBackslash = Path & ch Else AddBack ....Read More
Rating
ChangeFileExtension - Modify the extension in a file name
Total Hit (2922) «Code LangId=2» ' Change the extension of a file name ' if the last argument is True, it adds the extension even if the file doesn't ' have one Function ChangeFileExtension(ByVal FileName As String, _ ByVal Extension As String, Optional ByVal AddIfMissing As Boolean = False) _ As St ....Read More
Rating
CompareFiles - Comparing two binary/text files
Total Hit (2736) «Code LangId=2»' Returns a boolean indicating whether two files are equal ' Example: Debug.WriteLine(CompareFiles("D:\File1.mdb", "D:\File2.mdb")) Function CompareFiles(ByVal path1 As String, ByVal path2 As String) As Boolean Dim file1 As New System.IO.FileInfo(path1) Dim file2 As New ....Read More
Rating
ConcatenateFiles - Concatenating multiple text files
Total Hit (2828) «Code LangId=2» ' Concatenate a variable number of text files into a single result file ' ' Params: ' - resultFile: the complete path of the result file you want to create ' - header: a string that is written when a file is added to the result file. ' Note: this string can contain the #Fi ....Read More
Rating
CopyDirectory - Copy a directory
Total Hit (3036) «Code LangId=2» ' Copies a source directory to the destination directory. ' The last parameter specifies whether the files already present in the ' destination directory will be overwritten ' - Note: requires Imports System.IO ' - Usage: CopyDirectory("C:\Misc", "D:\MiscBackup") Sub CopyDire ....Read More
Rating
FolderHasFiles - Returns whether the specified folder has files
Total Hit (2681) «Code LangId=2» ' Returns a boolean indicating whether the specified folder has files Function FolderHasFiles(ByVal folderPath As String) As Boolean Return System.IO.Directory.GetFiles(folderPath).Length > 0 End Function «/Code»
Rating
FolderHasSubFolders - Returns whether the specified folder has sub-folders
Total Hit (2690) «Code LangId=2» ' Returns a boolean indicating whether the specified folder has sub-folders Function FolderHasSubFolders(ByVal folderPath As String) As Boolean Return System.IO.Directory.GetDirectories(folderPath).Length > 0 End Function «/Code» ....Read More
Rating
GetDirectorySize - Calculate the size of a directory
Total Hit (2778) «Code LangId=2» ' Returns the size of the specified directory ' - Note: requires Imports System.IO ' - Usage: Dim DirSize As Long = GetDirectorySize("D:\Projects") Function GetDirectorySize(ByVal DirPath As String) As Long Dim DirSize As Long Dim Dir As DirectoryInfo = New DirectoryInfo( ....Read More
Rating
GetResourceContent - Retrieving the content of an embedded text file
Total Hit (2640) «Code LangId=2» ' Retrieve the content of an embedded text file ' Note: the file must be included in the project as an embedded resource. ' - after adding the file to the project set its Build Action property to ' Embedded Resource ' ' Example: txtScript.Text = GetResourceContent("script.sql ....Read More
Rating
IsDriveReady - Returns whether a drive is ready
Total Hit (3127) «Code LangId=2» ' Returns a boolean indicating whether a given drive is ready ' Example: check if the floppy disk drive is ready ' Debug.WriteLine(IsDriveReady("a")) Function IsDriveReady(ByVal driveLetter As String) As Boolean If driveLetter.Length = 1 Then driveLetter &= ":\" Dim ....Read More
Rating
IsExecutableFile - Returns whether the file is an executable
Total Hit (2671) «Code LangId=2» ' Returns a boolean indicating whether the file is an executable Function IsExecutableFile(ByVal filePath As String) As Boolean ' add more extensions if you wish Dim extensions() As String = New String() {".exe", ".bat", ".com", ".pif"} ' return true if the extension ....Read More
Rating
IsImageFile - Returns whether the file is an image
Total Hit (3668) «Code LangId=2» ' Returns a boolean indicating whether the file is an image Function IsImageFile(ByVal filePath As String) As Boolean ' add more extensions if you wish Dim extensions() As String = New String() {".bmp", ".jpg", ".jpeg", ".gif", _ ".tif", ".tiff", ".png", ".tga", ....Read More
Rating
IsValidPath - Validating a system path
Total Hit (4588) «Code LangId=2»' Validate a system path ' Example: ' MessageBox.Show(IsValidPath("C:\Test\Memo.txt")) ' => True ' MessageBox.Show(IsValidPath("\\RemotePC\Test\Memo.txt")) ' => True ' MessageBox.Show(IsValidPath("C:\Test\Mem|o.txt")) ' => False Function IsValidPath(ByVal p ....Read More
Rating
LoadTextFile - Load the contents of a text file
Total Hit (2800) «Code LangId=2» ' Returns the content of the specified text file ' Note: it can throw an exception ' Usage: Dim FileContent As String = LoadTextFile("C:\Autoexec.bat") Function LoadTextFile(ByVal FilePath As String) As String Dim sr As System.IO.StreamReader Try sr = New ....Read More
Rating
SaveTextFile - Save or append text to a file
Total Hit (3658) «Code LangId=2» ' Saves a text file. If the destination file already exists, ' its content can be replaced, or the new content can be appended ' at the end of the file, according to the last parameter ' Note: the destination directory must exist, otherwise the file is not ' saved and th ....Read More
Rating
ArrayDeleteElement - Deleting an element in any type of array
Total Hit (2567) «Code LangId=2»' A generic routine that deletes an element in any type of array. ' Example: deleting the 2nd element of the array arr ' ArrayDeleteElement(arr, 1) Sub ArrayDeleteElement(ByVal arr As Array, ByVal index As Integer) ' Shift elements from arr(index+1) to arr(index). ....Read More
Rating
ArrayInsertElement - Inserting an element in any type of array
Total Hit (2615) «Code LangId=2»' A generic routine that inserts an element in any type of array. ' Example: inserting an entry of value 5 between the 1st and 2nd entry of the ' array arr ' ArrayInsertElement(arr, 1, 5) Sub ArrayInsertElement(ByVal arr As Array, ByVal index As Integer, _ Optional By ....Read More
Rating
ArrayListJoin - Merging two ArrayList objects
Total Hit (2869) «Code LangId=2»' A reusable function that merges two ArrayList objects ' Example: ' Dim al As New ArrayList() ' al.Add("Jack") ' al.Add("Mary") ' val.Add("Bob") ' al.Add("Tom") ' ' Dim al2 As New ArrayList() ' al2.Add("Frank") ' al2.Add("Lee") ' a ....Read More
Rating
FilterDuplicates - Delete duplicate items in an array
Total Hit (3195) «Code LangId=2» ' Filter out duplicate values in an array and compact ' the array by moving items to "fill the gaps". ' Returns the number of duplicate values ' ' The array is not REDIMed, but you can do it easily using ' the following code: ' a() is a string array ' dups = FilterDu ....Read More
Rating
HasDuplicateValues - Check if an array has duplicate values
Total Hit (3446) «Code LangId=2» ' Returns True if an array contains duplicate values ' it works with arrays of any type Function HasDuplicateValues(ByVal arr As Array) As Boolean Dim ht As New Collections.Hashtable(arr.Length * 2) Dim index As Integer For index = 0 To arr ....Read More
Rating
StripControlChars - Delete control characters in a string
Total Hit (4275) «Code LangId=2» ' Strip all control characters (ASCII code < 32) ' ' If the second argument is True or omitted, ' CR-LF pairs are preserved Function StripControlChars(ByVal source As String, Optional ByVal KeepCRLF As _ Boolean = True) As String ' we use this to build the result ....Read More
Rating
Age - Evaluating the age of a person, given his/her birth date
Total Hit (2086) «Code LangId=2»' Evaluate the age of a person, given his/her birth date ' Example: Debug.WriteLine(Age(#9/28/1980#)) ' => 22 Function Age(ByVal birthDate As Date, Optional ByVal currentDate As Date = #1/1/ _ 1900#, Optional ByVal exactAge As Boolean = True) As Integer If currentDate ....Read More
Rating
BusinessDateAdd - Adding or subtracting a number of business days from a date
Total Hit (2372) «Code LangId=2»' Add or subtract a number of business days from a date ' Example: Debug.WriteLine(BusinessDateAdd(#4/9/2003#, 5)) ' => 4/16/2003 Function BusinessDateAdd(ByVal startDate As Date, ByVal days As Integer, _ Optional ByVal saturdayIsHoliday As Boolean = True) As Date Do Wh ....Read More
Rating
BusinessDateDiff - Evaluating the number of business days between two dates
Total Hit (2486) «Code LangId=2» ' Evaluate the number of business days between two dates ' Example: Debug.WriteLine(BusinessDateDiff(#4/9/2003#, #4/25/2003#)) ' => 12 Function BusinessDateDiff(ByVal startDate As Date, ByVal endDate As Date, _ Optional ByVal saturdayIsHoliday As Boolean = True) As Integer ....Read More
Rating
EasterDate - Evaluating the Easter date for a given year
Total Hit (2711) «Code LangId=2»' Evaluate the Easter date for a given year ' Example: MessageBox.Show(EasterDate(2003).ToLongDateString()) Function EasterDate(ByVal year As Integer) As DateTime Dim g, c, h, i, j, l, month, day As Integer g = year Mod 19 c = year \ 100 h = ((c - (c \ 4) - ....Read More
Rating
GetRoshHashanah - Retrieving the date that Rosh Hashanah begins in the requested year
Total Hit (2365) «Code LangId=2» ' Returns the date that Rosh Hashanah begins for the requested year. ' It is important to note that Rosh Hashanah is based on the Lunar cycle so the ' Holiday actually begins at sunset of the day before the date returned by this ' function. ' Note: Many dates in the Jewish ....Read More
Rating
BinarySearch - Fast search in a sorted array
Total Hit (3302) «Code LangId=2» ' Binary search in an array of any type ' Returns the index of the matching item, or -1 if the search fails ' ' The arrays *must* be sorted, in ascending or descending ' order (the routines finds out the sort direction). ' LASTEL is the index of the last item to be searched, a ....Read More
Rating
SingularToPlural - Converting the input word from singular to plural
Total Hit (2463) «Code LangId=2»' Convert the input word from singular to plural Function SingularToPlural(ByVal singular As String) As String ' convert to lowercase for easier comparison Dim lower As String = singular.ToLower() Dim res As String ' rule out a few exceptions If lower = "f ....Read More
Rating
SplitQuoted - A split variant that deals correctly with quoted elements
Total Hit (1901) «Code LangId=2»' split a string, dealing correctly with quoted items ' ' TEXT is the string to be split ' SEPARATOR is the separator char (default is comma) ' QUOTES is the character used to quote strings (default is """", ' the double quote) ' you can also use a character pair (eg "{}") ....Read More
Rating
StartsWith - Check whether a string starts with one of multiple possible choices
Total Hit (1792) «Code LangId=2»' Check whether a string starts with one of multiple possible choices. ' Return -1 if no possible string matches the start of the source, ' otherwise return the index of the matching string. ' ' Examples: ' Debug.WriteLine(StartsWith("This is my test line", True, "this", ' ....Read More
Rating


(Page 61 of 133) 3985 Result(s) found  ... 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 ...

Recommanded Links

 

Home   |  Comment   |  Contact Us   |  Privacy Policy   |  Terms & Conditions   |  BlogsZappySys

© 2008 BinaryWorld LLC. All rights reserved.