Results 1 to 8 of 8

Thread: is it to long filename?

Threaded View

  1. #1

    Thread Starter
    Lively Member elmnas's Avatar
    Join Date
    Jul 2009
    Posts
    127

    is it to long filename?

    Hello people,

    I have following button that create a folder on the desktop
    also give the folder Volvo_Penta MM-dd-yyyy


    but it doesn't create the whole filename why?

    see code below
    Code:
       Private Sub CreateFolLab_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles CreateFolLab.Click
    
            Dim myPath As String = My.Computer.FileSystem.SpecialDirectories.Desktop
            Dim myFile As String = "VolvoPenta"
            Dim strPath As String = IO.Path.Combine(myPath, Now.ToString((myFile) + "MM-dd-yyyy"))
    
            If Len(Dir(strPath, vbDirectory)) = 0 Then
                MkDir(strPath)
            End If
    
    
    
        End Sub
    I get this result


    Could someone correct the code?




    Thank you in advance
    Last edited by elmnas; Jun 22nd, 2015 at 01:59 AM.

Tags for this Thread

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