Link to home
Start Free TrialLog in
Avatar of rito1
rito1

asked on

Extracting Text from String Variable

Hi All,

I have the follwing URL stored within a string variable...

http://localhost:80/myfoldername

Using C#, how can I extract everything after the last '/' and store in a separate variable. In this example its 'myfoldername'? 'myfoldername' will vary in characters/size so the next time it could be called 'abcfolder' for example.

Thanks,

Rit
SOLUTION
Avatar of sshah254
sshah254

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
ASKER CERTIFIED SOLUTION
Avatar of Paul Jackson
Paul Jackson
Flag of United Kingdom of Great Britain and Northern Ireland image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of rito1
rito1

ASKER

Thanks both.

Rit