CSC : error CS1548: Cryptographic failure while signing assembly xxx.dll Error signing assembly — Access is denied
Yesterday I got this error while building my application after installing Windows 7 x64. I thouoght it was because of X64 OS, but later I found it doesn’t have anything to do with X64 OS. I don’t know the actual problem or solution.You can fix this error by setting permissions.Browse to the following folder ‘C:\Users\All Users\Microsoft\Crypto\RSA’ and modify the security settings of the ‘MachineKeys‘ folder such that Everyone have read/write access to it and the Administrators have full control. Don’t worry if you couldn’t find “All Users” folder in the path, just put that path into Run and it will open the Path(Actually it is opening the same folder from ProgramData). Again I don’t know this is an actual fix or not, but it works
CaptureItPlus – A screen capture utility
Few days back I started working on another open source project, for capturing screen shots. It is similar or can be used as an alternative to Snipping Tool in Windows Vista / 7.
Here is the main features of CaptureItPlus
- Supports all major screen capture modes. Fullscreen, Window, Rectangle, FreeForm and Scheduled capture.
- Supports various output formats, JPG, PNG, GIF, BMP, WMF, and TIFF. Default format in PNG, but users can customize it using settings.
- Supports keyboard shortcuts(customization also) for capture modes
- Sound notification after capture.
- Supports capture screen with cursor.
- Written in Microsoft .Net 2.0; supports major operating systems.
- API support.
- Easy to install, no admin rights required.
- Support for executing plugins after screen capture.
- Licensed under GNU GPL v2.0. Full source code available(C# 2.0)
You can download latest version of CaptureItPlus from CodePlex.
Please try it and let me know your comments.
Windows 7 SDK Installation success or error status: 1603
Today my team lead asked me to install FxCop 10 for static code analysis(which is available as part of Windows 7 SDK.) in our projects. As I am using Visual Studio Professional edition, the inbuilt option for Static code analysis is not available. I downloaded the Windows 7 SDK ISO from http://www.microsoft.com/download/en/details.aspx?id=8442 link. And I am able to start the installation. After some time, I got a wiered error like the following -
After checking the log file I found a line like this. Installation success or error status: 1603. I searched for this particular error and it was a generic error, sometimes it was related to low disk space. I tried the installation serveral times and everytime I got the same error. Then I modified the installation options, I un-checked all the VC++ related options; which is not required for me. And its worked
Later I found some problem with the VC++ compiler options and Microsoft has released a patch for it. And you can down load it from http://www.microsoft.com/download/en/details.aspx?displaylang=en&id=4422
Happy Coding
How to fix Error Code 29506, While installing SQL Management Studio Express on Windows 7 x64
Today I started installing SQL Server Management Studio express on my Windows 7 x64, and I started installing it, after few seconds, I got an error message like this
This installer has encountered an unexpected error installing this package. This may indicate a problem with this package. The error code is 29506
My initial thought was may be it is because of some problem with my downloaded installer. I downloaded it again and still the problem exists. Then I tried it with commandline(cmd), with Run As Administrator option and its worked
How to use TaskDialog API in C#
The TaskDialog API replaces MessageBox. A message box is useful for prompting users for an acknowledgment, confirmation, or an answer to a yes or no question. Message boxes are popular because of the MessageBox function is convenient for developers to use. TaskDialog is the preferred API to use because it is similar to MessageBox but much more flexible. Previously, developers have created their own message box implementations when greater functionality was required. Unfortunately .Net framework doesn’t expose TaskDialog API directly; you need to use WIN32 api for it. Here is one Task dialog implementation in C#. Only limitation of Task Dialog API is it doesn’t supported by Windows operating systems less than Windows Vista.
Here is the API declarations.
[DllImport("comctl32.dll", CharSet = CharSet.Unicode, EntryPoint = "TaskDialog")]
static extern int TaskDialog(IntPtr hWndParent, IntPtr hInstance, String pszWindowTitle,
String pszMainInstruction, String pszContent, int dwCommonButtons,
IntPtr pszIcon, out TaskDialogResult pnButton);
//Dialog buttons
[Flags]
public enum TaskDialogButtons : int
{
Ok = 0x0001,
Cancel = 0x0008,
Yes = 0x0002,
No = 0x0004,
Retry = 0x0010,
Close = 0x0020
}
//Dialog Results
[Flags]
public enum TaskDialogResult : int
{
IDOK = 1,
IDCANCEL = 2,
IDRETRY = 4,
IDYES = 6,
IDNO = 7,
IDCLOSE = 8,
NONE = 0
}
//Dialog Icons
[Flags]
public enum TaskDialogIcon
{
Information = UInt16.MaxValue - 2,
Warning = UInt16.MaxValue,
Stop = UInt16.MaxValue - 1,
Question = 0,
SecurityWarning = UInt16.MaxValue - 5,
SecurityError = UInt16.MaxValue - 6,
SecuritySuccess = UInt16.MaxValue - 7,
SecurityShield = UInt16.MaxValue - 3,
SecurityShieldBlue = UInt16.MaxValue - 4,
SecurityShieldGray = UInt16.MaxValue - 8
}
And here is my TaskDialog wrapper function.
public static TaskDialogResult Show(IntPtr handle, string messageTitle, string mainTitle,
string mainContent, TaskDialogButtons taskDialogButtons, TaskDialogIcon taskDialogIcon)
{
TaskDialogResult buttonClicked = TaskDialogResult.IDCANCEL;
TaskDialog(handle, IntPtr.Zero, messageTitle, mainTitle, mainContent,
(int)taskDialogButtons, (IntPtr)(int)taskDialogIcon, out buttonClicked);
return buttonClicked;
}
And here is the screen shot of Task Dialog running in my Windows 7 machine.



