private void pUpdateFormulas(String currentName, String newName) {
int i = 0;
cReportControl rptCtrl = null;
for (i = 1; i <= m_report.getControls().count(); i++) {
rptCtrl = m_report.getControls().item(i);
cReportFormula w_formulaHide = rptCtrl.getFormulaHide();
if (w_formulaHide.getText() != "") {
if (w_formulaHide.getText().IndexOf(currentName, 1) != 0) {
w_formulaHide.setText(pReplaceInFormula(w_formulaHide.getText(), currentName, newName));
}
}
cReportFormula w_formulaValue = rptCtrl.getFormulaValue();
if (w_formulaValue.getText() != "") {
if (w_formulaValue.getText().IndexOf(currentName, 1) != 0) {
w_formulaValue.setText(pReplaceInFormula(w_formulaValue.getText(), currentName, newName));
}
}
}
}