dim r as new RegEx
r.SearchPattern = "(([a-zA-Z][0-9a-zA-Z+\\-\\.]*:)?/{0,2}[0-9a-zA-
Z;/?:@&=+$\\.\\-_!~*'()%]+)?(#[0-9a-zA-Z;/?:@&=+$\\.\\-_!~*'()%]+)?"
dim match as RegExMatch = r.Search(EditField1.Text)
if match <> nil then
MsgBox "Validated: " + match.SubExpressionString(0)
else
MsgBox "Failed."
end if
But it's not clear to me that this regular expression does quite what
one expects.
Charles Yeomans
On Aug 31, 2006, at 1:21 PM, Dennis Birch wrote:
Can you share an example of how you would use this in RB code? I am a
complete novice to Regex. My attempts to apply this following the
example code in the LR are resulting in nothing useful.
On 8/30/06, Walter Purvis <[EMAIL PROTECTED]> wrote:
> -----Original Message-----
> I am needing to validate the contents of an EditField as a
> properly formatted URL. Does someone have a good suggestion
> on how to accomplish this? Perhaps a REGEX?
Check this:
<http://www.geekpedia.com/Question65_How-to-validate-an-URL-using-
RegEx-in-C
sharp.html>
It uses this regex
(([a-zA-Z][0-9a-zA-Z+\\-\\.]*:)?/{0,2}[0-9a-zA-Z;/?:@&=+$\\.\\-_!
~*'()%]+)?(
#[0-9a-zA-Z;/?:@&=+$\\.\\-_!~*'()%]+)?
constructed according to the BNF grammar given in RFC 2396
(http://www.ietf.org/rfc/rfc2396.txt).
_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>
Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>
_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>
Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>