Thank you for your reply.
Can't the expression "in greeting" and "in thanks" be used in other contexts?
By the way, I've found many webpages wherein the expression smile in greeting is used. Here are some of them.
1)B’Elanna stepped onto the bridge and looked over at Harry’s station. He
faced her and smiled in greeting. She smiled back.
2)The eternally feuding Fascist greengrocer and Communist housepainter across the road, who had previously agreed only on the point that my hair was too long, smiled in greeting and sat down to the table for an animated game of scopa.
3)“Hey.” Remus Lupin sat down on another armchair near hers and smiled in greeting. When he smiled, Effie's heart skipped a beat, and she just smiled back
4)Well, on this particular morning, as I made my way up from the beach, there was a woman (whom I recognized from seeing often at the beach) holding a plastic bag of ripe golden apples in a liquid that looked just like plain water. She smiled in greeting and offered me a golden apple from the bag
And here are some where smile in thanks is used:
1)She looked over her shoulder and smiled in thanks.
2)“You’re going to do fine. You did well with James and your going to do well again.” he bent down and gave her a very soft kiss on the forehead. She smiled in thanks and grasped his hand tighter
3) Hayden stood up and said,” Actually I’ll pay for his things and my things together.” Ron smiled in thanks, while the old woman handed Ron the treats, as Hayden paid for the treats and sat back down in their cabin.
Is it improper usage? Or might it be a US/UK English difference?