Skip to main content

Posts

Showing posts from July, 2009

Version control for Flex Builder

1. Use Visual SourceSafe: If you're familiar with Microsoft Visual SourceSafe, it's a bit difficult to apply it in your Flex project. But I think you can use it. Just create a Source Safe project to contain all files in your Flex project. After that, check-out the file you want to work and use Flex Builder to edit. Steps: - Install Microsoft Visual SourceSafe to create your project - Add all of your project's folder and files into this project 2. Use Subversion: Method 1: - Install VisualSVN Server to create project repository URL - Install Subclipse - Create Flex project as SVN in File/New/Other... with the repository URL has been created. - Working with version control inside Flex Method 2: - Install VisualSVN Server to create project repository URL - Install TortoiseSVN - Add the folder contains your Flex project into your project repository URL - Working with version control outside Flex 3. Use CVS: I'm not using it frequently, so I'll update it later.

How to move many records have the same value between two grids

private void MoveManyRecords(DataGridView dtL, DataGridView dtR, int iColToCheck) { if (dtL.CurrentCell == null) return; int iCurrentRowIndex = 0, i = 0; int iLastRow = 0; iCurrentRowIndex = dtL.CurrentCell.RowIndex; string strColToCheckValue = dtL[iColToCheck, iCurrentRowIndex].Value.ToString(); int j = 0; while (j < dtL.Rows.Count) { if (dtL[iColToCheck, j].Value.ToString().Equals(strColToCheckValue)) { dtR.Rows.Add(); iLastRow = dtR.Rows.Count - 1; for (i = 0; i < dtL.Columns.Count; i++) { dtR[i, iLastRow].Value = dtL[i, j].Value; } dtR.Rows[iLastRow].Selected = true; dtR.CurrentCell = dtR.Rows...

How to move entire row between two grids

private void MoveRecord(DataGridView dtL, DataGridView dtR) { if (dtL.CurrentCell == null) return; int iCurrentRowIndex = 0, i = 0; int iLastRow = 0; iCurrentRowIndex = dtL.CurrentCell.RowIndex; dtR.Rows.Add(); iLastRow = dtR.Rows.Count - 1; for (i = 0; i { dtR[i, iLastRow].Value = dtL[i, iCurrentRowIndex].Value; } dtR.Rows[iLastRow].Selected = true; dtR.CurrentCell = dtR.Rows[iLastRow].Cells[1]; dtL.Rows.RemoveAt(iCurrentRowIndex); }