String stuff

  • Thread starter Thread starter Fraggle
  • Start date Start date
F

Fraggle

I want to do this

if NOT absField.text = "" AND NOT
absField.text.StartsWith("http://")

absField.text = "http://" & absField.text

end if

IE check a string is not empty, then check it starts with http:// and
if not insert the http bit.

I would like to do the "starts with" bit case INsensitive, but I am
not sure how too.

Thanks

Fragg
 
Try this:

<WatchForWrapping>

If Not absField.Text.ToLower.StartsWith("http://") Then
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top