Modifying Crystal Reports v1.0.38 Forms - visual-studio-2005

You read that correctly, CR v1.0.38. We have an archaic piece of coldfusion software that uses reports created in CR v1.0.38. Some of these reports need minor adjustments, so I open it using Visual Studio make the adjustments. When I go to save it I'm prompted with a warning about only being able to save it as a newer version. When I attempt to pull the report using the saved .rpt file it locks up.
Do any of you CR gurus know how I could edit and save a CR report into CR v1.0.38 format? The only Crystal Reports editing software I currently have is Visual Studio 2005.

You could try using a text editor such as TextPad or NotePad++ to try and edit the .rpt file. It's possible that such an early version of Crystal will have a fairly simplistic model that may be succesfully modified "in the raw." Especially if the changes you need to make are indeed simple. I don't expect any Crystal editor written since '95 to be able to read a 1.* rpt file.
I have actually done something similar in version 5 of Crystal to address a persistence bug. (Crystal 5 threw in an extra squiggly brace on save sometimes into rpt file... )
EDIT: Found a page of links to Crystal Utils that may help you. Perhaps better options than text editing the raw rpt!

Wow, old enough that it was actually called Quik Reports. Oldest thing I know for editing Crystal Reports would be the version that comes with VB5 (or VB6 - same version) which was version 4.6 - there's a chance this might be old enough. If you can get an even older version, apparently Crystal has been bundled with VB since 1993, which would mean VB3.

Related

Build Data Table Error (DataTable could not be read)

As seen above, there’s some error with the building of data table… Any help here?
Error message is as follows:
Creating dtData2: Type ‘UiPath.Core.GenericValue, UiPath.System.Activities, Version=20.4.0.0, Culture=neutral, PublicKeyToken=null’ is not allowed here. See https://go.microsoft.com/fwlink/?linkid=2132227 for more information.
2nd upload as per requested:
You might be using a .xaml file from a newer version of Studio. The BuildDataTable seems to be picky about that.
I encountered that mysterious crash on our production system after some third party developers made some code changes. I noticed the version of UIPath generic object in my crash screen was 19.10.x.x, and I know our Production and Test/Dev systems are on v18.x.
I suspected they sent us code developed in a newer version of Studio, or copied and pasted remotely from their Studio to ours and it happened to work (at least the pasting). I got a complaint from the users that the robot didn't work so they'd just do it manually until it could be fixed.
To "fix", edit the .xaml in Studio. Find the Build Data Table in the Activities and created a new code block. Since the Build command is so simple, needing only the output dt field, that might be the easiest option. I reran it in debugging with the new "BuildDataTable" acitivity and it didn't throw the exception. [I probably could've downgraded the genericvalue version number in the .xaml file, but I was already in Studio.]
You can also use "findstr" to search for the BuildDataTable commands from the .xaml file. The findstr or egrep command can show you the version of the genericvalue UIPath is trying to stuff into the empty datatable on creation:
<ui:BuildDataTable DataTable="[DetailDT]" DisplayName="Details Data Table"
xs:element name="Change_x0020_Type_x0020_Index"
...
msdata:DataType="UiPath.Core.GenericValue, UiPath.System.Activities, Version=19.10.1.0,
One of the nicer "features" of UIPath is their use of a sort of open format .xaml file for all the code storage. Using findstr or egrep has really helped find hidden problems spread across our large collection of folders. Their xaml is not as easy as merging code written in autoIt3 or AutoHotKey, as they have graphic screen size elements and block number tags embedded in it, but at least all the graphical code blocks aren't completely locked away in some compressed or OLE format as would be tempting for software that works (only?) on Windows.
Check your UiPath.System.Activities version. I had the same error with a DataTable containing another DataTable as a column. Basic datatypeas as string and int were no problem, but a DataTable threw the error.
I updated UiPath.System.Activities to 20.10.4 (from 19 something) and it worked after that. Also tried with 21.10.4 and that works as well.

Stop SSRS from Building ALL reports when Previewing

I am trying to find some sort of setting in Visual Studio that controls whether it Builds all the report in the solution before letting the user Preview a report.
Currently, I am updating an old report. When I try to preview, the Visual Studio preview goes blank white for about 10 minutes then gives a bunch of errors about issues with different reports.
The report preview failed because the report could not be built.
Unfortunately, Microsoft's MSDN is pretty much useless when searching for something (or anytime you want actual information and not theory). I've looked through every item in the Visual Studio menu but haven't found anything that sounds close to what I want.
It did not build all reports last week when I made changes to another report. I have other solutions which do not currently have the problem (it would make more sense if they did, tho). What setting did I change to make this stupid functionality?
I would recommend opening that report in Report Builder. It's a free download. You can use the 3.0 version or 2016. That way it will not be bogged down by the other reports, it has simpler error handling, and it has pretty much all the same editing capabilities. Once you're done making any changes, you can continue to manage it from within Visual Studio SSDT.
This is not intended as an answer but too long for a comment.
If a report has not been successfully built previously, it will be built when you preview any report. Once the build completes, reports are skipped unless they have been changed since the last succesful build.
Usually when you preview a report, it builds just that report and skips the others.
You can prove this by going to a 'working' solution/project, right-clicking the solution and choosing Clean Solution. This will delete the build info for all the reports, next time you preview any report, every report will be rebuilt, you can see this in the Output window.
Once this is complete, preview any report and in the Output windows you will see Skipping 'report name.rdl'. Item is up to date.
I 'think' the status of each report is held in the project user options file (*.rptpoj.user) but I don't have anything that I can read the file sensibly with so I'm not 100% certain.
You may have to create new project and copy each report in one at a time fixing them as you go, I can't think of anything else, but hopefully somebody know more than me.

Mass migration of Crystal Reports from v10 to Visual Studio 2010

I have been tasked with reviewing "SAP Crystal Reports for Visual Studio 2010" and the "SAP Crystal Reports 2011" standalone as potential upgrade paths from Crystal Reports v10.
I've installed the extension to Visual Studio 2010 (and went through the common troubles of updating the runtime to get the viewer working) and can open report files and save them. Consequently, I get the "this report was saved in a previous version of CR, saving will upgrade the report file format" dialog. I've tested on a couple of reports and the conversion goes ahead smoothly and the resultant file remains compatible with our server software.
My problem is I have over 1,500 reports. I'd like to avoid opening each one in turn and saving/converting individually. Is there a way to convert all the report files in one fell swoop? Some means of scripting Visual Studio to do it, maybe?
Notes:
I've added every report file to a project and attempted to Save All... no dice.
I must convert every single report now. It's not an option to just convert those that need changes when they need changes.
My work network access is locked down pretty tight. The bureaucratic process to get any utilities or tools installed on my machine is INTENSE and must be justified.
We don't use any features of CR standalone that aren't shipped with VS.
P.S. It's worth re-iterating that I'm also reviewing CR2011. I'll need to do the same thing with the standalone designer too.
Why not use Windows PowerShell? I've written a PowerShell wrapper around the Crystal Reports SDK named PsCrystal. My goal is to make it easier to script the mundane tasks that I encounter each day.
You should be able to adapt the (sole) example to suit your needs. I will add more examples in the near future. Feel free to help the project, if you want.
Check if this tool will work for you:
http://www.r-tag.com/Pages/CRDataSource.aspx
It is actually replacing the connection, but will upgrade the reports too.
Thanks to Craig and Lan for their input (you get an upvote), but Ryan addressed my problem within the comments of my question (and even did so after I gave him sass!).
For those with broken scroll-wheels and/or extraordinarily short screens:
For VS2010, you could easily create a simple program to open each .rpt
file in a directory and then re-save it (The web is full of examples
in the language of your choice). Doing this in CR2011 is a little
trickier... I'd try a script in something like AutoIT.
Thanks, Ryan, for reminding me that I'm working with an API. Not just a dev environment.

Problem in Add Reference dialog with paths containing #

I am new to using Microsoft development tools but have been using Visual Studio 2010, .NET 4 and C# for the past few weeks. I ran into a problem yesterday creating a new project the same way I have been doing it successfully from the start: right-click on the project in the Solution Explorer → Add Reference, which used to bring up this dialog:
Old Dialog Box http://img514.imageshack.us/img514/8978/oldaddreferencedialogue.jpg
After a couple of weeks of no new projects I went to create one yesterday and got a new Add Reference dialog. And trying to add the same dll I have been adding for weeks now resulted in the error seen here:
New Dialog http://img692.imageshack.us/img692/2074/newaddreferencedialogue.png
So, after a painful day trying to determine the cause, it looks to me like it has something to do with the new dialog choking on the # I had in my reference path. When I removed the # everything works as expected. Considering Microsoft has two .NET languages with # in the name, I am surprised that this issue keeps biting people (I have heard of this problem over the years, but I have never done much with Microsoft tools until recently, so of course I did not recall it.)
Questions from a Visual Studio newbie:
Is it common knowledge to not use # in paths?
How/why did I get this new Add Reference dialog when my colleagues, using the same VS version, still have the old dialog that handles # in paths just fine?
My opinion is that if you use weird characters in paths, you get what you deserve. :)
I know there are bugs about '#' character in paths in the core VS product, in addition to whatever may be in the Pro Power Tools extension. There is a surprising amount of code that goes to/from URIs and filenames, and '#' characters (and everything thereafter) get dropped when roundtripping via a System.Uri.
In general, I think it's safe to assume that when creating filenames/paths, there will be 10,000 tools of various quality trying to parse the filenames, and a (large) subset of those tools will fail on 'weird' characters. Just avoid weird characters whenever possible. You gotta choose your battles. In an ideal world, tools would be robust to these kinds of issues. In the real world, it's better to name a path "CSharp" rather than "C#" and move on with more important things in life.
The second dialog is the one from the VS2010 productivity power tools pack - I havent used it myself so dont know of any problems with it. Have you recently installed this?

TFS annotate/blame summary report for a project

In Team Foundation Server, I know that you can use the Annotate feature to see who last edited each line in a particular file (equivalent to "Blame" in CVS). What I'd like to do is akin to running Annotate on every file in a project, and get a summary report of all the developers who have edited a file in the project, and how many lines of code they currently "own" in that project.
Aside from systematically running Annotate of each file, I can't see a way to do this. Any ideas that would make this process faster?
PS - I'm doing to this to see how much of a consultant's code still remains in a particular (rather large) project, not to keep tabs on my developers, in case you're worried about my motivation :)
It's easy enough to use the "tf.exe history" command recursively across a directory of files in TFS. This will tell you who changed what files.
However what you're after is a little bit more than this - you want to know if the latest versions of any files have lines written by a particular user.
The Team Foundation Power Tools ship with a command-line version of annotate called "tfpt.exe annotate". This has a /noprompt option to direct the output to the console, but it only outputs the changeset id - not the user name.
You could also use the TFS VersionControl object model to write a tool that does exactly what you need.
If you install the TFS Power tools (at least for VS2005); it's called annotate.
It might be part of VS2008...
You can use TFS Analysis Cube to see generate a code churn report, which I believe is something you would like.
Annotate is now part of Visual Studio (I think it was introduced in VS 2010).
Docs
I'm writing an answer to an 8 year old question :). Its not really a full answer, but a suggestion to look into excel reports for TFS.
TFS2013 / 2015 on prem has something has an excel report that can be used to visualize Code Churn.
In VS open team explorer then select "Documents" then explode "Excel Reports". I believe Code Churn report has something like discussed. The report is made by some default project template so I think tfs2013 on prem just creates it.
Code Churn Excel Report VS2015
https://msdn.microsoft.com/en-us/library/dd695782.aspx
I had very similar requirement to get details of particular attribute in a file e.g. who added, when, related work items etc.; Following GitHub project is having implementation to get required details and required minimal changes to work with multiple files or project -
SonarQube SCM TFVC plugin
It requires analysis to be executed from Windows machines with the Team Foundation Server Object Model installed (download for TFS 2013).
This blog post is also having good explaination and sample application -
TFS SDK: Connecting to TFS 2010 & TFS 2012 Programmatically

Resources