I need to create an RStringF object using a string literal, "Busy here". I need to pass this as the second argument to CSIPResponseElements::NewLC(); The signature of CSIPResponseElements::NewLC(); is as follows
static IMPORT_C CSIPResponseElements *NewLC(TUint aStatusCode, RStringF aReasonPhrase);
First I create an RStringPool object:
RStringPool* pool = new RStringPool();
Now I call CSIPResponseElements::NewLC(), by creating the RStringFobject on the fly by calling OpenFStringL() method of the RStringPool object, by passing const TesC8& as argument. The argument to OpenFStringL() is also created on the fly using _LIT8().
The code is as follows:
CSIPResponseElements *pResponseElements = CSIPResponseElements::NewLC(486, pool->OpenFStringL(_LIT8(KResphrase, "Busy Here")));
I get an expression syntax error for the above line.
Any suggestions would be appreciated.