-4

How can I declare the following xpath value as a string variable in C#?

Value: //*[contains(concat( " ", @class, " " ), concat( " ", "lit-movie", " " ))]

Dariusz Woźniak
  • 9,640
  • 6
  • 60
  • 73
Emad
  • 31
  • 5

1 Answers1

0

You have to use escape characters (use backslash), so " should be replaced by \":

string xpath = "//*[contains(concat( \" \", @class, \" \" ), concat( \" \", \"lit-movie\", \" \" ))]";

Dariusz Woźniak
  • 9,640
  • 6
  • 60
  • 73