Share

AcString::replace

C++

Adesk::Int32 replace(
    wchar_t wchOld, 
    wchar_t wchNew
);

Description

Replaces a character with another character.

Parameters

Parameters Description
wchOld Input character to be replaced by wchNew
wchNew Input new character to replace wchOld

Returns

Number of replaced instances of the wchOld. Zero, if the string is not changed.

Links

AcString

Previous Declaration

AutoCAD 2017 through AutoCAD 2024

ACBASE_PORT int replace(wchar_t wchOld, wchar_t wchNew);

History

AutoCAD 2025

Function now returns Adesk::Int32 instead of int.

Was this information helpful?