Пример #1
0
        private void RefreshData(CalcCell changedCell)
        {
            xls.SetCellFromString(changedCell.XlsRow, 1, changedCell.Content);
            xls.Recalc();

            foreach (CalcCell cell in CollectionView.VisibleCells)
            {
                cell.Result = xls.GetStringFromCell(cell.XlsRow, 1);
            }
        }
Пример #2
0
        public override UICollectionViewCell GetCell(UICollectionView collectionView, NSIndexPath indexPath)
        {
            var cell = (CalcCell)collectionView.DequeueReusableCell(CalcCellId, indexPath);

            cell.XlsRow     = indexPath.Row + 1;
            cell.Heading    = new TCellAddress(indexPath.Row + 1, 1).CellRef;
            cell.Content    = GetCellOrFormula(indexPath.Row + 1);
            cell.ActiveCell = x => ActiveEdit = x;
            cell.Result     = xls.GetStringFromCell(indexPath.Row + 1, 1);
            cell.OnRefresh  = RefreshData;
            return(cell);
        }