Looking for a great text editor for a great price. Check out pspad can't beat the features or speed for the price.
It will syntax color most file types out of the box. There are other syntax defintions and plugins in the download center.
Looking for a great text editor for a great price. Check out pspad can't beat the features or speed for the price.
It will syntax color most file types out of the box. There are other syntax defintions and plugins in the download center.
Automated testing of you Web apps in IE
WatiN will run scripts http://watin.sourceforge.net/ there is also a recorder to make you life a bit easier. Checkout WatiN Test Recorder http://watintestrecord.sourceforge.net/
Your search cannot be completed because this site is not assigned to an indexer
If you get this error you have most likely not assigned and indexer when creating the content Database
Go into :
SharePoint 3.0 Central Administration -> Application Management -> SharePoint Web Application Management -> Content databases -> Content Database used for the site > Set the Search Server
Google now has its own FREE 411 service
Link to site: GOOG411
1-800-GOOG-411
It seems like I have been using 411 a bunch lately and now it will only cost you what a 1-800 call usually does.
Breaking up a long SQL file using powershell
We got a 111 Gig SQL script and it would not load into anything to be run, so I wrote this poershell script to split it up, I am splitting it up on any line greater than 60000 that has an Insert command.
Just slung some code quick and dirty
process
{
# Read Arg0 as the input file
$fs = new-object System.IO.FileStream($args[0], [System.IO.FileMode]::Open, [System.IO.FileAccess]::Read)
$fs.open
$sr = new-object System.IO.StreamReader($fs)
# setup the new file name based on Arg1 if Arg1 is myfile.sql, files created will be myfile0.sql, myfile1.sql ...
$basefilename = $args[1]
$extension = $args[1]
$lastindex = $extension.LastIndexOf('.')
$basefilename = $basefilename.Substring(0, $basefilename.length -($basefilename.length - $lastindex))
$extension = $extension.Substring($lastindex)
$basefilename
$extension
$currpart = 0
$currentfilename = $basefilename + $currpart + $extension
$currentfilename
$os = new-object System.IO.FileStream($currentfilename, [System.IO.FileMode]::Create, [System.IO.FileAccess]::Write)
$os.open
$sw = new-object System.IO.StreamWriter($os)
$linecount = 0
# while there is a line to read
while ($sr.Peek() -ge 0)
{
# read a line
$i = $sr.ReadLine()
#check to see if we are past a line limit and we have found a good breaking point for the file
if (($linecount -gt 60000) -and ($i.SubString(0,11) -eq "INSERT INTO"))
{
$sw.flush()
$os.close()
$currpart = $currpart + 1
$currentfilename = $basefilename + $currpart + $extension
$currentfilename
$os = new-object System.IO.FileStream($currentfilename, [System.IO.FileMode]::Create, [System.IO.FileAccess]::Write)
$os.open
$sw = new-object System.IO.StreamWriter($os)
$sw.writeline($i)
$linecount = 0
}
else
{
$sw.writeline($i)
$linecount = $linecount + 1
}
}
$sw.flush()
$os.close()
$fs.close()
}
Reading an XML file into code as objects in Visual Studio
With the xsd.exe included in Visual Studio, creating a object based on your XML file is easier than ever.
XmlSerializer serializer = new XmlSerializer(typeof(yourFields));
XmlTextReader rdrYourFields = new XmlTextReader(new System.IO.StringReader(YourData));
yourFields fields = (yourFields)serializer.Deserialize(rdrYourFields);