You must Sign In to post a response.
  • Category: .NET

    Hi to all ,how can write these below vb6 statements into c# language.

    VB6 STATEMENTS: If (InStr(Len(sLocation), sLocation, "\") = 0) And sLocation <> "" Then
    sLocation = sLocation & "\"
    End If
    If Not FSO.FolderExists(sLocation & "ExportFiles") Then
    FSO.CreateFolder (sLocation & "ExportFiles")
    End If
    sLocation = sLocation & "ExportFiles\" & sFileName
  • #584711
    try this


    if ((Strings.InStr(Strings.Len(sLocation), sLocation, "\\") == 0) & !string.IsNullOrEmpty(sLocation))
    {
    sLocation = sLocation + "\\";
    }
    if (!FSO.FolderExists(sLocation + "ExportFiles"))
    {
    FSO.CreateFolder(sLocation + "ExportFiles");
    }
    sLocation = sLocation + "ExportFiles\\" + sFileName;


    Regards
    N.Ravindran
    Your Hard work never fails

  • #584730
    try this code



    if ((Strings.InStr(Strings.Len(sLocation), sLocation, "\\") == 0) & !string.IsNullOrEmpty(sLocation))
    {
    sLocation = sLocation + "\\";
    }
    if (!FSO.FolderExists(sLocation + "ExportFiles"))
    {
    FSO.CreateFolder(sLocation + "ExportFiles");
    }
    sLocation = sLocation + "ExportFiles\\" + sFileName;




    hope this will help you


  • This thread is locked for new responses. Please post your comments and questions as a separate thread.
    If required, refer to the URL of this page in your new post.