Hi, We are opening incidents successfully with sd_event agaist HP ServiceDesk. We'd now like to fill the longer textfields with structured text containing NewLine characters. The sd_event seems to convert the NewLines into "#" and then stumbles over these.
Has anybody successfully acomplished this task and can share the trick ?
Igor, thanks very much - a very good hint. In experimenting over the weekend, I also have found another solution: When I send "\\n" instead of the newline, sd_event seems to transfer a real "\n" across. And this is then is seen as a correct newline again. Cheers, Michael
Hi Kevin, sorry - I made a mistake. It's actually "\n" I'm sending accross - just in Perl its written "\\n" to make it "\n": If have two Perl scripts, one prepares the text and uses following expressions -- $text =~ s/#/+/g; -- $text =~ s/\n/\\n/g; to remove all "#" and to replace NewLines with literal "\n". $text is thenb written to a file, adn I can see the "\n" in there. The second script then reads this text in (from the file) and passes it to sd_event: ... -- $lb = `cat $filename`; -- $vlist = "..... lb=\'$lb\' ....."; -- system "sd_event ... -v $vlist"; ... "lb" is the receiving field in HPSD, and I have included it in simple quotes when passing it to sd_event.