Posts

Showing posts from July, 2010

SVN CHANGE FINDER

Image
Everyone knows how cool of a software svn is.Along with tools like visualsvn, tortoisesvn,ankh svn,svn monitor it makes you feel happy all day as with out being worried about your data.Like everyone else programmer/developers uses svn a lot in their daily routine for keeping revisions of their source files alongs with any other documentaion.When you want to find a change a colleague made in a file or wonder when that change is made, you have to almost reap through all the revisions of the file and use the diff tools/viewers open each revision and see if change is there.It is hectic time consuming when there are many revisions on a file and if there are lot of changes per revision.So I created this small utility to find when the text/change you are looking is made in a file.

Set SvnExeLocation and TortoiseExeLocation in the config.xml before using the application.




Get the code and binaries from the link below.


Keywords:
svn subversion changes revisions head diff diffs log author messag…

Crystal Reports Windows Application - Failed to open the connection

Failed to open the connection.
Details: [Database Vendor Code: 4060 ]
Failed to open the connection.
temp_62a7065e-b077-44f0-8593-7dca04303f6a {7498BCDB-812A-4D53-B04E-9BD3E45EC6B6}.rpt
Details: [Database Vendor Code: 4060 ]
Stack Trace:
at CrystalDecisions.ReportAppServer.Controllers.RowsetControllerClass.CreateCursor(ISCRGroupPath GroupPath, RowsetMetaData MetaData, Int32 Reserved)
at CrystalDecisions.ReportAppServer.CrystalReportDataView.EnsureDataTableIsFilled()
at CrystalDecisions.ReportAppServer.CrystalReportDataView.get_DataView()
at CrystalDecisions.ReportAppServer.CrystalReportDataView.get_InternalCollection()
at CrystalDecisions.ReportAppServer.CrystalReportDataView.get_Count()


OK, the error above appeared out of no where and we had to spend hours and hours to figure out what is going on.

Let's get some info about the environment.

Dev database - where developers write code against and is used to design new reports.

QA database - where qa staff run the test cases in th…

svnadmin dump - never finishes

Ok, here I am trying to separate a repository into two following svn documentation.I got to create a dump file then use svndumpfilter to create separate dump files for the projects I want and create repo's using those individual files.

With this in mind I started to work on it.Our repo is about 5 gigs in size.Command prompt in which I started the command says not responding after a while and never finishes dumping.I thougt it needed more time so let it go for the entire night with no success.After all these hours I
found out that dump is written to the console window.Changing that to output to file fixed the problem

Wrong
svadmin dump e:\repo e\repodump

Correct(if you want the dump file)
svadmin dump e:\repo >e\repodump

Finding the Owner( Launching Form)

Sometimes it is very useful to have reference to the form that launches another form.This is easily done by passing the owner in the form show method.But what if you have to change a lot in the existing code to get that.You can use windows api to get the owner.Lets say you have form1 and form2 in your app and form2 is launched from form1 and if we want to find the launcher of form2 which in our case is form1.This is what you do in form2.


<dllimport("user32", charset:="CharSet.Auto," exactspelling:="True)" setlasterror:="True,">_
Public Shared Function GetWindow(ByVal hwnd As IntPtr, ByVal uCmd As Integer) As Integer
End Function


--get the window now
Dim i As Integer
i = GetWindow(Me.Handle, 4)
Dim ctrl As Control = Form.FromHandle(i)