c# - DLLImport works in VS but not in IIS -


We have SOAP websites that use third-party DLLs. In Visual Studio, when I run the program, it works perfectly but it can find dll but when I put this project in IIS, then the webservice DLL can not be found. Here is the DllImport part below. [DllImport (@ "/ dll / y1d431_mit.dll", EntryPoint = "Y1DPackG", SetLastError = false, ExactSpelling = true)] Private Static Extern Zero Y1DPackG (Reference Integer ErrorNumb, Ref Integer ErrorMsgs, String RegCustomer, Integer RegPassword, Integer CostOptim, Integer IgnoreLast, Integer EffortLev, Integer ReduceLays, Integer PrefShort, Integer DiffStocks, Integer DiffPieces, Integer ReusLength, Integer GapItIt, Integer GapItEnd, Integer GapGripEnd, Integer OptimTime, Integer IterMult, Integer LayByMark, Integer RunMsgMode, Integer ReservInp2, ref rounding stoc KGrLth, referee integer StockGrCst, referee, less StockGrQty, referee integer PartGrLth, referee integer PartGrMrkID, referee partGrQty, referee integer critsum, referee integer Effsum, referee integer StockSum, referee integer partSum, referee integer lengthSum, referee integer WasteSum, ref rounder CostSum, Ref Integer LastStockNo, Ref Integer LastParts, Ref Integer LastLength, Ref Integer LastWaste, Ref Integer LastCost, Ref Integer PatternSum, Ref Integer LayoutSum, Ref Integer Lay OutCuts, ref rounding ReservOut1, referee intra reserve 2, referee short stockjrno, referee short partgro no, ref short partstock no, referee short stocklain, referee short stock patent, referee short stockparts, ref in stockwatch);

According to the DLLPort statement where is the IIS DL file? According to DLLIPEEP statement to find IIS, where should I place DLL files?

Load up Sysinternal is free before you run that code before launching it to dllimport Executes and errors are collected after the errors. This tool tells you everything that is going on, in which IIS starts searching for it. Apart from this, it will tell you that you are getting permission errors.

Permission errors are likely to occur when it is 32-bit DLL on a 64-bit system, because DLLs are then run through WOW64 and they are probably copied. By default, the WOW64 directory for execution is not a directory that is accessible to any of the unknown Internet user accounts.

Comments

Popular posts from this blog

java - ImportError: No module named py4j.java_gateway -

python - Receiving "KeyError" after decoding json result from url -

.net - Creating a new Queue Manager and Queue in Websphere MQ (using C#) -