How do I specify a wildcard (for ANY character) in a c# regex statement?

Posted by Scott on Stack Overflow See other posts from Stack Overflow or by Scott
Published on 2010-06-14T00:53:15Z Indexed on 2010/06/14 1:02 UTC
Read the original article Hit count: 155

Filed under:
|
|

Trying to use a wildcard in C# to grab information from a webpage source, but I cannot seem to figure out what to use as the wildcard character. Nothing I've tried works!

The wildcard only needs to allow for numbers, but as the page is generated the same every time, I may as well allow for any characters.

Regex statement in use:

Regex guestbookWidgetIDregex = new Regex("GuestbookWidget(' INSERT WILDCARD HERE ', '(.*?)', 500);", RegexOptions.IgnoreCase);

If anyone can figure out what I'm doing wrong, it would be greatly appreciated!

© Stack Overflow or respective owner

Related posts about c#

Related posts about .NET