IdentifiantMot de passe
Loading...
Mot de passe oublié ?Je m'inscris ! (gratuit)
Navigation

Inscrivez-vous gratuitement
pour pouvoir participer, suivre les réponses en temps réel, voter pour les messages, poser vos propres questions et recevoir la newsletter

ASP.NET MVC Discussion :

Publier une application asp.net mvc sur hebergement avec VS 2013


Sujet :

ASP.NET MVC

  1. #1
    Futur Membre du Club
    Femme Profil pro
    Développeur .NET
    Inscrit en
    Janvier 2015
    Messages
    9
    Détails du profil
    Informations personnelles :
    Sexe : Femme
    Localisation : Belgique

    Informations professionnelles :
    Activité : Développeur .NET

    Informations forums :
    Inscription : Janvier 2015
    Messages : 9
    Points : 8
    Points
    8
    Par défaut Publier une application asp.net mvc sur hebergement avec VS 2013
    J'utilise Visual Studio 2013. J'ai créé une application asp.net MVC qui affiche un simple "Hello world". J'ai généré puis j'ai fait click droit sur le projet, publier, j'ai choisis le mode ftp et j'ai renseigné les information de mon serveur puis j'ai cliqué sur publier. Ensuite VS me dit que ça été correctement publié. La je vais voir mon site intenet et mon navigateur me dit qu'il y a une erreur. Pourtant quand j'ouvre filezilla, je vois que des fichiers ont été créé dans le bon dossier.

    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
    31
    32
    33
    34
    35
    36
    37
    38
    39
    40
    41
     
    Server Error in '/' Application.
    Could not load file or assembly 'Microsoft.Web.Infrastructure, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The system cannot find the file specified.
    Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
     
    Exception Details: System.IO.FileNotFoundException: Could not load file or assembly 'Microsoft.Web.Infrastructure, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The system cannot find the file specified.
     
    Source Error:
     
    An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.
     
    Assembly Load Trace: The following information can be helpful to determine why the assembly 'Microsoft.Web.Infrastructure, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' could not be loaded.
     
     
    WRN: Assembly binding logging is turned OFF.
    To enable assembly bind failure logging, set the registry value [HKLM\Software\Microsoft\Fusion!EnableLog] (DWORD) to 1.
    Note: There is some performance penalty associated with assembly bind failure logging.
    To turn this feature off, remove the registry value [HKLM\Software\Microsoft\Fusion!EnableLog].
     
     
    Stack Trace:
     
     
    [FileNotFoundException: Could not load file or assembly 'Microsoft.Web.Infrastructure, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The system cannot find the file specified.]
       System.Web.WebPages.PreApplicationStartCode.Start() +0
       System.Web.Mvc.PreApplicationStartCode.Start() +32
     
    [InvalidOperationException: The pre-application start initialization method Start on type System.Web.Mvc.PreApplicationStartCode threw an exception with the following error message: Could not load file or assembly 'Microsoft.Web.Infrastructure, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The system cannot find the file specified..]
       System.Web.Compilation.BuildManager.InvokePreStartInitMethodsCore(ICollection`1 methods, Func`1 setHostingEnvironmentCultures) +547
       System.Web.Compilation.BuildManager.InvokePreStartInitMethods(ICollection`1 methods) +132
       System.Web.Compilation.BuildManager.CallPreStartInitMethods(String preStartInitListPath, Boolean& isRefAssemblyLoaded) +102
       System.Web.Compilation.BuildManager.ExecutePreAppStart() +153
       System.Web.Hosting.HostingEnvironment.Initialize(ApplicationManager appManager, IApplicationHost appHost, IConfigMapPathFactory configMapPathFactory, HostingEnvironmentParameters hostingParameters, PolicyLevel policyLevel, Exception appDomainCreationException) +521
     
    [HttpException (0x80004005): The pre-application start initialization method Start on type System.Web.Mvc.PreApplicationStartCode threw an exception with the following error message: Could not load file or assembly 'Microsoft.Web.Infrastructure, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The system cannot find the file specified..]
       System.Web.HttpRuntime.FirstRequestInit(HttpContext context) +9930568
       System.Web.HttpRuntime.EnsureFirstRequestInit(HttpContext context) +101
       System.Web.HttpRuntime.ProcessRequestNotificationPrivate(IIS7WorkerRequest wr, HttpContext context) +254
     
     
    Version Information: Microsoft .NET Framework Version:4.0.30319; ASP.NET Version:4.0.30319.34212
    Cordialement

  2. #2
    Membre expérimenté
    Homme Profil pro
    Développeur .NET
    Inscrit en
    Février 2007
    Messages
    871
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Âge : 40
    Localisation : Canada

    Informations professionnelles :
    Activité : Développeur .NET

    Informations forums :
    Inscription : Février 2007
    Messages : 871
    Points : 1 502
    Points
    1 502
    Par défaut
    Salut,

    T'as verifie que ton serveur peut bien faire tourner iis avec la meme version du frmaework dotnet que celui que tu as utiliser pour developper.

    A priori cela ressemble a ce genre de probleme: http://stackoverflow.com/questions/1...ral-publickeyt

  3. #3
    Futur Membre du Club
    Femme Profil pro
    Développeur .NET
    Inscrit en
    Janvier 2015
    Messages
    9
    Détails du profil
    Informations personnelles :
    Sexe : Femme
    Localisation : Belgique

    Informations professionnelles :
    Activité : Développeur .NET

    Informations forums :
    Inscription : Janvier 2015
    Messages : 9
    Points : 8
    Points
    8
    Par défaut Problème résolu
    Résolu j'ai fait "Update-Package Microsoft.Web.Infrastructure -Reinstall" dans le Package Manager https://docs.nuget.org/consume/package-manager-console et ça marche

+ Répondre à la discussion
Cette discussion est résolue.

Discussions similaires

  1. Réponses: 4
    Dernier message: 24/08/2011, 09h30
  2. Réponses: 0
    Dernier message: 30/05/2011, 10h42
  3. publier une application ASP.NET sur VS 2005
    Par insane_80 dans le forum ASP.NET
    Réponses: 5
    Dernier message: 24/09/2008, 14h43

Partager

Partager
  • Envoyer la discussion sur Viadeo
  • Envoyer la discussion sur Twitter
  • Envoyer la discussion sur Google
  • Envoyer la discussion sur Facebook
  • Envoyer la discussion sur Digg
  • Envoyer la discussion sur Delicious
  • Envoyer la discussion sur MySpace
  • Envoyer la discussion sur Yahoo