Results 1 to 2 of 2

Thread: Add reference for winSCP DLL not working in Production Server

  1. #1
    FirasKassim is offline VB.NET Forum Newbie
    .NET Framework
    .NET 4.5
    Join Date
    Apr 2015
    Posts
    1
    Reputation
    0

    Add reference for winSCP DLL not working in Production Server

    Hi,

    I have basic knowledge in c#, I'm developing a website by using visual studio 2012, one fuction is to sftp file to remote server, I noticed that sftp is not supported by asp.net, I downloaded third party dll file (winSCP), in the visual studio I did add reference to the dll file and I could sftp and work normally. but then when I needed to transfer my website to the production server, I got error below:

    Compiler Error Message:
    CS0246: The type or namespace name 'WinSCP' could not be found (are you missing a using directive or an assembly reference?)


    Line 10: using System.IO;

    Line 11: using System.Xml.XPath;

    Line 12: using WinSCP;

    Line 13: using System.Web.SessionState;

    Line 14: using System.Threading;


    C:\Windows\SysWOW64\inetsrv> "C:\Windows\Microsoft.NET\Framework\v4.0.30319\csc .exe" /t:library /utf8output /R:"C:\Windows\Microsoft.Net\assembly\GAC_MSIL\Micr osoft.CSharp\v4.0_4.0.0.0__b03f5f7f11d50a3a\Micros oft.CSharp.dll" /R:"C:\Windows\Microsoft.Net\assembly\GAC_32\System .Data\v4.0_4.0.0.0__b77a5c561934e089\System.Data.d ll" /R:"C:\Windows\Microsoft.Net\assembly\GAC_MSIL\Syst em.Web.DynamicData\v4.0_4.0.0.0__31bf3856ad364e35\ System.Web.DynamicData.dll" /R:"C:\Windows\Microsoft.Net\assembly\GAC_MSIL\Syst em.Core\v4.0_4.0.0.0__b77a5c561934e089\System.Core .dll" /R:"C:\Windows\Microsoft.Net\assembly\GAC_MSIL\Micr osoft.VisualStudio.Web.PageInspector.Loader\v4.0_1 .0.0.0__b03f5f7f11d50a3a\Microsoft.VisualStudio.We b.PageInspector.Loader.dll" /R:"C:\Windows\Microsoft.Net\assembly\GAC_MSIL\Syst em.Drawing\v4.0_4.0.0.0__b03f5f7f11d50a3a\System.D rawing.dll" /R:"C:\Windows\Microsoft.Net\assembly\GAC_32\System .Web\v4.0_4.0.0.0__b03f5f7f11d50a3a\System.Web.dll " /R:"C:\Windows\Microsoft.Net\assembly\GAC_MSIL\Syst em.ServiceModel.Web\v4.0_4.0.0.0__31bf3856ad364e35 \System.ServiceModel.Web.dll" /R:"C:\Windows\Microsoft.Net\assembly\GAC_MSIL\Syst em.Web.Extensions\v4.0_4.0.0.0__31bf3856ad364e35\S ystem.Web.Extensions.dll" /R:"C:\Windows\Microsoft.Net\assembly\GAC_MSIL\Syst em.Runtime.Serialization\v4.0_4.0.0.0__b77a5c56193 4e089\System.Runtime.Serialization.dll" /R:"C:\Windows\Microsoft.NET\Framework\v4.0.30319\m scorlib.dll" /R:"C:\Windows\Microsoft.Net\assembly\GAC_MSIL\Syst em.ComponentModel.DataAnnotations\v4.0_4.0.0.0__31 bf3856ad364e35\System.ComponentModel.DataAnnotatio ns.dll" /R:"C:\Windows\Microsoft.Net\assembly\GAC_MSIL\Syst em.ServiceModel\v4.0_4.0.0.0__b77a5c561934e089\Sys tem.ServiceModel.dll" /R:"C:\Windows\Microsoft.Net\assembly\GAC_MSIL\Syst em.Data.DataSetExtensions\v4.0_4.0.0.0__b77a5c5619 34e089\System.Data.DataSetExtensions.dll" /R:"C:\Windows\Microsoft.Net\assembly\GAC_MSIL\Syst em\v4.0_4.0.0.0__b77a5c561934e089\System.dll" /R:"C:\Windows\Microsoft.Net\assembly\GAC_MSIL\Syst em.IdentityModel\v4.0_4.0.0.0__b77a5c561934e089\Sy stem.IdentityModel.dll" /R:"C:\Windows\Microsoft.Net\assembly\GAC_MSIL\Syst em.ServiceModel.Activities\v4.0_4.0.0.0__31bf3856a d364e35\System.ServiceModel.Activities.dll" /R:"C:\Windows\Microsoft.Net\assembly\GAC_MSIL\Syst em.Xml.Linq\v4.0_4.0.0.0__b77a5c561934e089\System. Xml.Linq.dll" /R:"C:\Windows\Microsoft.Net\assembly\GAC_MSIL\Syst em.Web.WebPages.Deployment\v4.0_2.0.0.0__31bf3856a d364e35\System.Web.WebPages.Deployment.dll" /R:"C:\Windows\Microsoft.Net\assembly\GAC_MSIL\Syst em.ServiceModel.Activation\v4.0_4.0.0.0__31bf3856a d364e35\System.ServiceModel.Activation.dll" /R:"C:\Windows\Microsoft.Net\assembly\GAC_MSIL\Syst em.Web.Entity\v4.0_4.0.0.0__b77a5c561934e089\Syste m.Web.Entity.dll" /R:"C:\Windows\Microsoft.Net\assembly\GAC_MSIL\Syst em.Xml\v4.0_4.0.0.0__b77a5c561934e089\System.Xml.d ll" /R:"C:\Windows\Microsoft.Net\assembly\GAC_MSIL\Syst em.Web.WebPages.Deployment\v4.0_1.0.0.0__31bf3856a d364e35\System.Web.WebPages.Deployment.dll" /R:"C:\Windows\Microsoft.Net\assembly\GAC_MSIL\Syst em.Activities\v4.0_4.0.0.0__31bf3856ad364e35\Syste m.Activities.dll" /R:"C:\Windows\Microsoft.Net\assembly\GAC_MSIL\Syst em.Web.Services\v4.0_4.0.0.0__b03f5f7f11d50a3a\Sys tem.Web.Services.dll" /R:"C:\Windows\Microsoft.Net\assembly\GAC_MSIL\Syst em.Web.ApplicationServices\v4.0_4.0.0.0__31bf3856a d364e35\System.Web.ApplicationServices.dll" /R:"C:\Windows\Microsoft.Net\assembly\GAC_MSIL\Micr osoft.VisualStudio.Web.PageInspector.Runtime\v4.0_ 1.0.0.0__b03f5f7f11d50a3a\Microsoft.VisualStudio.W eb.PageInspector.Runtime.dll" /R:"C:\Windows\Microsoft.Net\assembly\GAC_32\System .EnterpriseServices\v4.0_4.0.0.0__b03f5f7f11d50a3a \System.EnterpriseServices.dll" /R:"C:\Windows\Microsoft.Net\assembly\GAC_MSIL\Syst em.WorkflowServices\v4.0_4.0.0.0__31bf3856ad364e35 \System.WorkflowServices.dll" /R:"C:\Windows\Microsoft.Net\assembly\GAC_MSIL\Syst em.Configuration\v4.0_4.0.0.0__b03f5f7f11d50a3a\Sy stem.Configuration.dll" /out:"C:\Windows\Microsoft.NET\Framework\v4.0.30319 \Temporary ASP.NET Files\root\07c93e6a\1853e4e4\App_Web_1p011v4r.dll" /DEBUG /debug+ /optimize- /w:4 /nowarn:1659;1699;1701;612;618 /warnaserror- "C:\Windows\Microsoft.NET\Framework\v4.0.30319\Tem porary ASP.NET Files\root\07c93e6a\1853e4e4\App_Web_1p011v4r.13.c s" "C:\Windows\Microsoft.NET\Framework\v4.0.30319\Tem porary ASP.NET Files\root\07c93e6a\1853e4e4\App_Web_1p011v4r.3.cs " "C:\Windows\Microsoft.NET\Framework\v4.0.30319\Tem porary ASP.NET Files\root\07c93e6a\1853e4e4\App_Web_1p011v4r.1.cs " "C:\Windows\Microsoft.NET\Framework\v4.0.30319\Tem porary ASP.NET Files\root\07c93e6a\1853e4e4\App_Web_1p011v4r.18.c s" "C:\Windows\Microsoft.NET\Framework\v4.0.30319\Tem porary ASP.NET Files\root\07c93e6a\1853e4e4\App_Web_1p011v4r.11.c s" "C:\Windows\Microsoft.NET\Framework\v4.0.30319\Tem porary ASP.NET Files\root\07c93e6a\1853e4e4\App_Web_1p011v4r.6.cs " "C:\Windows\Microsoft.NET\Framework\v4.0.30319\Tem porary ASP.NET Files\root\07c93e6a\1853e4e4\App_Web_1p011v4r.4.cs " "C:\Windows\Microsoft.NET\Framework\v4.0.30319\Tem porary ASP.NET Files\root\07c93e6a\1853e4e4\App_Web_1p011v4r.16.c s" "C:\Windows\Microsoft.NET\Framework\v4.0.30319\Tem porary ASP.NET Files\root\07c93e6a\1853e4e4\App_Web_1p011v4r.5.cs " "C:\Windows\Microsoft.NET\Framework\v4.0.30319\Tem porary ASP.NET Files\root\07c93e6a\1853e4e4\App_Web_1p011v4r.14.c s" "C:\Windows\Microsoft.NET\Framework\v4.0.30319\Tem porary ASP.NET Files\root\07c93e6a\1853e4e4\App_Web_1p011v4r.2.cs " "C:\Windows\Microsoft.NET\Framework\v4.0.30319\Tem porary ASP.NET Files\root\07c93e6a\1853e4e4\App_Web_1p011v4r.0.cs " "C:\Windows\Microsoft.NET\Framework\v4.0.30319\Tem porary ASP.NET Files\root\07c93e6a\1853e4e4\App_Web_1p011v4r.12.c s" "C:\Windows\Microsoft.NET\Framework\v4.0.30319\Tem porary ASP.NET Files\root\07c93e6a\1853e4e4\App_Web_1p011v4r.17.c s" "C:\Windows\Microsoft.NET\Framework\v4.0.30319\Tem porary ASP.NET Files\root\07c93e6a\1853e4e4\App_Web_1p011v4r.7.cs " "C:\Windows\Microsoft.NET\Framework\v4.0.30319\Tem porary ASP.NET Files\root\07c93e6a\1853e4e4\App_Web_1p011v4r.10.c s" "C:\Windows\Microsoft.NET\Framework\v4.0.30319\Tem porary ASP.NET Files\root\07c93e6a\1853e4e4\App_Web_1p011v4r.15.c s" "C:\Windows\Microsoft.NET\Framework\v4.0.30319\Tem porary ASP.NET Files\root\07c93e6a\1853e4e4\App_Web_1p011v4r.9.cs " "C:\Windows\Microsoft.NET\Framework\v4.0.30319\Tem porary ASP.NET Files\root\07c93e6a\1853e4e4\App_Web_1p011v4r.8.cs " Microsoft (R) Visual C# Compiler version 4.0.30319.18408 for Microsoft (R) .NET Framework 4.5 Copyright (C) Microsoft Corporation. All rights reserved.


    d:\inetpub\wwwroot\Dev_Final\intermediateLoad.aspx .cs(12,7): error CS0246: The type or namespace name 'WinSCP' could not be found (are you missing a using directive or an assembly reference?) d:\inetpub\wwwroot\Dev_Final\Profile_result.aspx.c s(12,7): error CS0246: The type or namespace name 'WinSCP' could not be found (are you missing a using directive or an assembly reference?) d:\inetpub\wwwroot\Dev_Final\Search.aspx.cs(12,7): error CS0246: The type or namespace name 'WinSCP' could not be found (are you missing a using directive or an assembly reference?)
    Please I need your help ... thanks a lot in advance,

    Firas

  2. #2
    JohnH's Avatar
    JohnH is offline VB.NET Forum Moderator
    .NET Framework
    .NET 4.5
    Join Date
    Dec 2005
    Location
    Norway
    Posts
    15,065
    Reputation
    2800
    Thread closed, VB.Net Forums is for VB.Net discussions. Try C# Developer Forums

Bookmarks

Posting Permissions

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