if(!hasAttr)
aNewParams = anInputParams;
else
- aNewParams = aOldParameters+"|"+anInputParams;
+ {
+ int pos = aOldParameters.SearchFromEnd("|");
+ if(pos==-1) pos = 0;
+ TCollection_AsciiString previousParamFull(aOldParameters.Split(pos));
+ TCollection_AsciiString previousParam(previousParamFull);
+ TCollection_AsciiString theRepet("1");
+ pos = previousParam.SearchFromEnd(";*=");
+ if(pos >= 0)
+ {
+ theRepet = previousParam.Split(pos+2);
+ pos = pos-1;
+ if(pos==-1) pos = 0;
+ previousParam.Split(pos);
+ }
+ if(previousParam == anInputParams)
+ {
+ theRepet = theRepet.IntegerValue()+1;
+ aNewParams = aOldParameters + previousParam + ";*=" + theRepet;
+ }
+ else
+ {
+ aNewParams = aOldParameters + previousParamFull + "|" + anInputParams;
+ }
+ }
if(VARIABLE_DEBUG)
{