Results 1 to 2 of 2

Thread: [RESOLVED] getting filename from a sitename

  1. #1

    Thread Starter
    Frenzied Member
    Join Date
    Sep 2005
    Posts
    1,364

    Resolved [RESOLVED] getting filename from a sitename

    e.g.

    http://www.mysite.com/hello/hi/anotherfolder/test.jpg would give me test.jpg

    http://www.my.site.com/test2/jpg would give me test2.jpg

    etc

    any ideas guys?

  2. #2
    I'm about to be a PowerPoster! Hack's Avatar
    Join Date
    Aug 2001
    Location
    Searching for mendhak
    Posts
    58,333

    Re: getting filename from a sitename

    VB Code:
    1. Private Sub Command1_Click()
    2. Dim strURL As String
    3. Dim arrFileName() As String
    4. strURL = "http://www.mysite.com/hello/hi/anotherfolder/test.jpg"
    5. arrFileName = Split(strURL, "/")
    6. MsgBox arrFileName(UBound(arrFileName))
    7. End Sub

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width