What I am trying to say is I want to extract www.abcd.com or www.efgh.in from the URLs using Split function.
The URLs i am supposed fetch files from contain single files only. You are right that the .ppt and .doc will come from the content type of the page.
What I want is if a '/' or A '#' is encountered wherever in the URL, the part before it should be taken as the filename. i.e
if
www.abcd.com?file/search is URL then www.abcd.com?file should be the file name.
and if
www.abcd.com/search is URL then www.abcd.com should be the file name. Same is the Case with '#'
I want to split the URL at the first '/' or first '#' and use it.
BTW Thank you for ur Reply