Saturday, January 24, 2015

Borland Together Database Reverse Engineering

You can perform a database reverse engineering to import schema from an existing database. Then Borland Together will generate an ER diagram for you.


You must use an account with administrative privilege.

Foreign keys can be added by using the Foreign Key link button from the diagram Palette and "Propagate Attributes" context menu command.




Create a Successful Online Store at Bigcommerce! Try it Free Now!

Borland Together Image Export - Modify File History

It is pretty easy, just Modify [workspace]\.metadata\.plugins\com.borland.tg.gde.imageexport\dialog_settings.xml.


Create a Successful Online Store at Bigcommerce! Try it Free Now!

Borland Together Report Generation (PDF) - Out of Memory Issue

In case out of memory issue occurred, you may try to allocate larger JVM size by updating Together.ini and eclipse.ini with appropriate -Xmx value.

If this does not work, you could try to use command line to generate report. Steps:

  1. go to the installation directory of Borland Together, eg C:\Borland\Together 
  2. run the command from the command prompt: gendoc "[project name]" "[package name]" -recursive -d "[output folder]" -format PDF -data "[workspace location]" 


eg. gendoc "project1" "com.project1.package1" -recursive -d "c:/temp/" -format PDF -data "c:\project".

Regarding the OutOfMemoryError, you may try to update C:\Borland\Together\gendoc.cmd by replacing 

set TG_JAVA_OPTIONS=-XX:MaxPermSize=256m -Xms512m -Xmx1024m

with 
set TG_JAVA_OPTIONS=-XX:MaxPermSize=256m -Xms512m -Xmx1024m -XX:SurvivorRatio=2.

Usage of gendoc.cmd:
gendoc.cmd [project name [package name]] [options]

[project name]       name of the project.
[package name]       name of the package.

[options] are:
  -help                  Display command line options
  -d <directory>         Destination directory for output files
  -template              Name of default template or path to template file
  -format                Documentation format: HTML, TXT, RTF, PDF or XSL-FO
  -nodiagrams            Do not create diagrams' pictures
  -hyperlinks            Include hyperlinked files' contents into documentation
  -audits                Include audits results into documentation
  -browser               Open documentation in browser


Create a Successful Online Store at Bigcommerce! Try it Free Now!

RadGridView – Animate Backcolor Of Grouped Row

The version of Telerik Winforms is 2010 SP1.


RadControls support animating many properties.
To animate the backcolor of a grouped row, you need to implement the ViewCellFormatting event handler with the following logic.
void radGridView1_ViewCellFormatting(object sender, CellFormattingEventArgs e)
{
 AnimatedPropertySetting setting = new AnimatedPropertySetting();

 setting.Property = GridCellElement.BackColorProperty;
 setting.StartValue = oldColor;
 setting.EndValue = newColor;
 setting.Interval = 100;
 setting.NumFrames = 50;
 setting.AnimatorStyle = AnimatorStyles.AnimateAlways;
 setting.ApplyEasingType = RadEasingType.Default;
 setting.UnapplyEasingType = RadEasingType.OutCircular;
 setting.ApplyValue(e.CellElement.RowElement);
}


Create a Successful Online Store at Bigcommerce! Try it Free Now!

RadGridView - Chagne Forecolor and Backcolor Of Grouped Row

The version of Telerik Winforms is 2010 SP1.
It's simple to change the forecolor, you need to implement the ViewCellFormatting event handler.
void radGridView1_ViewCellFormatting(object sender, CellFormattingEventArgs e)
{
 e.cellElement.ForeColor = Color.Blue;
}
While it's a little bit tricky to change the backcolor. You should not directly manipulate the cell element, like the following:
void radGridView1_ViewCellFormatting(object sender, CellFormattingEventArgs e)
{
 e.CellElement.BackColor = Color.Yellow
}
Instead, you need to use the row element.
void radGridView1_ViewCellFormatting(object sender, CellFormattingEventArgs e)
{
 e.CellElement.RowElement.BackColor = Color.Yellow
}


Create a Successful Online Store at Bigcommerce! Try it Free Now!