on*********@post.cz wrote:
std::string s("Some text is here");
std::string::size_type pos = s.find("text");
if (pos == std::string::npos)
{
// Not found
}
else
{
// Substring is on index pos
}
Hi, Thanks for this code, But i tried this before asking question and
found that it is not working.
what is wrong in following code?
//cFwdTaskList=allstream_LNP_install,allstream_LNP_d isconnect,allstream_native_install,allstream_nativ e_disconnect,allstream_change_TN,allstream_change_ 411,allstream_change_BNS,allstream_change_411_911_ PICCare_BNS,allstream_move,allstream_cmo_disconnec t,allstream_change_PIC,allstream_add_alternate_TN, allstream_remove_alternate_TN,allstream_LNP_reinst ate,allstream_remove_alternate_TN,allstream_altern ate_change_411,allstream_alternate_change_BNS,alls tream_alternate_cmo_disconnect
//functionNm=allstream_move
bool SoapCallProtocol::isPresentInFwdList(RWCString functionNm)
{
TRACE (4, "in isPresentInFwdList");
std::string s(cFwdTaskList);
std::string::size_type pos = s.find(functionNm);
if (pos == std::string::npos)
{
TRACE (4, "You are executing the function :" << functionNm);
TRACE (4, "function :" << functionNm<<"is not present in fwd
list.");
return false;
}
else
{
TRACE (4, "You are executing the function :" << functionNm);
TRACE (4, "function :" << functionNm<<"is present in fwd list.");
return true;
}
TRACE (4, "By default returning false.");
return false;
}