Archive for the ‘Visual Studio’ Category

Well, since the special field “Page n of m” in Crystal Reports gets translated to the current language set for the application and you might not want that, this solves this problem:

  • Drag the special field “Page Number” onto the report.
  • Right click and select “Format¬†Object”.
  • Select the “Show string” button (X+2) and enter the following:
    ‘Page ‘ + totext(pagenumber, 0)+ ‘ of ‘ + totext(totalpagecount, 0)
  • You can change the text ‘Page ‘ and ‘ of ‘ to whatever you want…

Read Full Post »

Today I’m working in a project which¬†previously has exclusive checkout right set to on. I changed this today, as I think that it’s generally not a good idea to have it like this (only one user can checkout a file a time).

However, I still got the error message “No items were checked out – The item is locked for check-out by”… error message in Visual Studio, I guess this is because the file was checked out prior to the exclusive checkout change. To fix this, I had to run the following command in a Visual Studio command prompt:

tf undo /workspace:<workspace name>;<user name> $”<path to file>”

Replace the values between <> with the appropriate values). The workspace name/user name and path was found in the output windows in Visual studio:

No items were checked out
The item $/THEPROJ/DEV-Branch/client/src/Client/frmMainMDI.cs is locked for check-out by donald.duck in workspace LATEST_REAL.

For the values above, this shoud be:

tf undo /workspace:LATEST_REAL;donald.duck $”/THEPROJ/DEV-Branch/client/src/Client/frmMainMDI.cs “

Read Full Post »