-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
  • 8,677
  • 5
  • 52
  • 70
Emad
  • 21
  • 4

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
  • 8,677
  • 5
  • 52
  • 70