Gacutil not installed by default in VisualStudio - visual-studio

I am unable to add an assembly into GAC. Please assist in getting it work. I ran following command in VisualStudio13 CMD
gacutil /i “<C:\Program Files\ibm\IBM DATA SERVER DRIVER>\bin\netf40_32\IBM.Data.DB2.Entity.dll”
Error Message:
Command "gacutil" is not valid.
Also, i checked there is also no gacutil.exe file on path
C:\Program Files (x86)\Microsoft SDKs\Windows\v7.0A\Bin\NETFX 4.0
Tools
But when i access the path there is no gacutil file as shown:

The issue was Windows Explorer path(C:\Program Files (x86)\Microsoft SDKs\Windows\v7.0A\Bin\NETFX 4.0 Tools\gacutil.exe) had no "gacutil.exe". Accessing the same path through cmd listed down "gacutil.exe" as present.
Thus, instead of just giving command gacutil-i to add an assembly in cache, i gave full path
C:\Program Files (x86)\Microsoft SDKs\Windows\v7.0A\Bin\NETFX 4.0Tools\gacutil.exe -i
Don't trust windows explorer. Trust command credits# Sir Conrad Frix-Comments

You can either drag-drop the .dll into c:\windows\assembly folder or check C:\Program Files (x86)\Microsoft SDKs\Windows\v10.0A\bin\NETFX 4.6 Tools\x64 for gacutil as its part of .net framework, not your IDE. Hope it helps!

Related

Visual Studio 2017 msbuild package sharepoint

I have a simple SharePoint 2013 solution which I can publish through Visual Studio - this will generate .wsp for me. However when I am trying to run build by the command:
msbuild /t:Package mySolution.sln
Build is ok but during packaging I receive an error:
C:\Program Files (x86)\Microsoft Visual
Studio\2017\Enterprise\MSBuild\Microsoft\VisualStudio\v15.0\SharePointTools\Microsoft.VisualStudio.SharePoint.targets(190,5): error : Could not load file or assembly
'Microsoft.VisualStudio.Modeling.Sdk.15.0, Version=15.0.0.0,
Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its
dependencies. The system cannot find the file specified.
If I put this missing dll to C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\MSBuild\Microsoft\VisualStudio\v15.0\SharePointTools then I receive another error about another missing dll...
What am I doing wrong?
Looks like this is MSBuild issue:
1.Open elevated command prompt
2.Navigate to your SDK tools
cd "C:\Program Files (x86)\Microsoft SDKs\Windows\v10.0A\bin\NETFX 4.6.1 Tools\x64"
Sn -Vr "C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\Common7\IDE\PrivateAssemblies\Microsoft.VisualStudio.Modeling.Sdk.15.0.dll"
gacutil /i "C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\Common7\IDE\PrivateAssemblies\Microsoft.VisualStudio.Modeling.Sdk.15.0.dll"
For the following three dlls, please do same behavior from step 3 to 4
C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\Common7\IDE\PublicAssemblies\Microsoft.VisualStudio.SharePoint.dll
Note if Microsoft.VisualStudio.SharePoint.dll not found in above path, check in
C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\MSBuild\Microsoft\VisualStudio\v15.0\SharePointTools\Microsoft.VisualStudio.SharePoint.dll
C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\Common7\IDE\PrivateAssemblies\Microsoft.VisualStudio.SharePoint.Designers.Models.dll
C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\Common7\IDE\PrivateAssemblies\Microsoft.VisualStudio.SharePoint.Designers.Models.Features.dll
Now you can MSBuild your SharePoint 2016 solutions by VS command promp.
Check Link, that's for Sharepoint 2016, but same works for 2013 as well: https://developercommunity.visualstudio.com/content/problem/40195/cant-use-msbuild-to-package-sharepoint-2016-soluti.html

How to add a reference to C:\Windows\Microsoft.NET\assembly

How can I reference a .NET assembly deployed in c:\windows\microsoft.net\assembly from Visual Studio IDE?
If i do right click on References/Add Reference, it only shows the c:\windows\assembly content.
How do I add a reference to new GAC path (c:\windows\microsoft.net\assembly)?
Go to the location via CMD C:\Program Files (x86)\Microsoft SDKs\Windows\v8.0A\bin\NETFX 4.0 Tools
Type Gacutil -i {Path of the dll}
OR
Open visual studio commond promt and type Gacutil -i {Path of the dll}
It's working by adding a reference to:
C:\Windows\Microsoft.NET\assembly\GAC_MSIL\\
I don't know if it is the better way to do it but it seems to do the job.
For registering the DLL in another environment, I used the following sentence:
"%ProgramFiles(x86)%\Microsoft SDKs\Windows\v8.1A\bin\NETFX 4.5.1 Tools\gacutil.exe" /i /f
Hope it helps.

'Cannot find DAO350.dll' file error VB6

After installing VB6 successfully on my Windows 8.1 64bit pc, whenever i am trying to open my .vbp project file it gives me an error can't find DAO350.dll file. Googled for every possible solution but couldn't find one.
Please help me.
[UPDATE]
[UPDATE1]: It looks something like this
The DA0350.dll must be registered.
Try this:
On the Visual Basic 6.0 CD (or whatever your installation source is), locate the Dao350.dll file, and then copy it to the directory c:\program files\common files\microsoft shared\DAO. (The Dao350.dll file is located in the \os\system folder on the Visual Basic 6.0 CD.)
To register this file, click Start, click Run, and then type or paste the following line:
Regsvr32 "c:\program files (x86)\common files\microsoft shared\DAO\Dao350.dll"
Update:
The VB6TMPL.TLB is probably not installed for your current user.
Try to run Visual Basic as administrator and/or try this: http://support.microsoft.com/kb/262976/en-us
To solve about "Can't find file DAO350.DLL"
Download DAO350.DLL file from https://www.dll-files.com/dao350.dll.html
Extract file DLL, then copy file DAO350.DLL to C:\Program Files (x86)\Microsoft Visual Studio\VB98 or any other place you install VB 6
Try open your VB 6
Work for me.
From the command prompt, execute the following commands:
cd C:\Program Files (x86)\Common Files\Microsoft Shared\DAO
regsvr32 dao350.dll
This should do it.
On the Visual Basic 6.0 CD (or whatever your installation source is), locate the Dao350.dll file, and then copy it to the directory C:\Program Files\Microsoft Visual Studio\VB98.
After applying this fix. The Visual Basic 6 can now run successfully on your Computer.
NOTE: The Dao350.dll file is located in the \os\system folder on the Visual Basic 6.0 CD.

VS2012 doesn't include winres.h any more?

After installing VS2012, I can't find winres.h under folder "C:\Program Files (x86)\Microsoft Visual Studio 11.0\VC". What happen to VS2012 and why remove this header file?
By the way, in VS2010, winres.h locates in "C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\atlmfc\include"
The file is part of the Windows SDK now and since VS2012 the SDK location is different, it's now called a 'Kit' and is found in Program Files/Windows Kits. Sepcifically you can find winres.h in
C:\Program Files (x86)\Windows Kits\8.0\Include\um

Can’t uninstall infragistics. Can’t find gacutil

Am trying to uninstall infragistics, but i get an error at the end of the uninstall saying 'Windows cannot find gacutil. Make sure you typed the name correctly and then try again'. I navigate to this path 'C:\Program Files (x86)\Microsoft SDKs\Windows\v8.0A\bin\NETFX 4.0 Tools' and the gacutil file is there. Any idea on these? Am stuck with infragistics and i can’t uninstall them.
In order to reference gacutil as a command you need to add the location of gacutil.exe to your environmental variables.
C:\Program Files (x86)\Microsoft SDKs\Windows\v8.0A\bin\NETFX 4.0 Tools

Resources