MCPcopy Create free account
hub / github.com/SeleniumHQ/selenium / PartialLinkText

Method PartialLinkText

dotnet/src/webdriver/By.cs:267–278  ·  view source on GitHub ↗

Gets a mechanism to find elements by a partial match on their link text. The partial link text to find. A object the driver can use to find the elements. If is null.

(string partialLinkTextToFind)

Source from the content-addressed store, hash-verified

265 /// <returns>A <see cref="By"/> object the driver can use to find the elements.</returns>
266 /// <exception cref="ArgumentNullException">If <paramref name="partialLinkTextToFind"/> is null.</exception>
267 public static By PartialLinkText(string partialLinkTextToFind)
268 {
269 if (partialLinkTextToFind == null)
270 {
271 throw new ArgumentNullException(nameof(partialLinkTextToFind), "Cannot find elements when partial link text is null.");
272 }
273
274 return new By(PartialLinkTextMechanism, partialLinkTextToFind)
275 {
276 Description = "By.PartialLinkText: " + partialLinkTextToFind
277 };
278 }
279
280 /// <summary>
281 /// Gets a mechanism to find elements by their tag name.

Calls

no outgoing calls