25 March 2011

Error on enabling CLR in SQL2005

It happens when i simulate with my new production server. after i move my source web application to the new server, this error show up. the cause of this error that i read is this:
The CLR integration is not enabled by default when we create a stored procedure project in VS 2005,and you deployed in SQL 2005
To enable execution of .Net Code in SQL 2005, this is the script you need, run it in the running instance of SQL 2005; it will enable .net CLR code.

EXEC sp_configure 'clr enabled', 1;

RECONFIGURE WITH OVERRIDE;

GO

To disable execution of .Net Code in SQL 2005, this is the script you need, run it in the running instance of SQL 2005; it will enable .net CLR code.

EXEC sp_configure 'clr enabled', 0;

RECONFIGURE WITH OVERRIDE;

GO

The second way to enable .Net code in SQL 2005 stored procedures, is to use SQL Server Surface Area Configuration.

From Start-> programs -> SQL 2005->Configuration tools ->SQL Surface Area Configuration.

Click with Surface area configuration for features.
Just click on Enable CLR integration and click apply and ok.

taken from http://www.c-sharpcorner.com/UploadFile/dsdaf/CLRSQL20507292006084224AM/CLRSQL205.aspx

Error when login windows 2003 server: Generic host process for win32 services has encountered a problem and needed to close

Once upon the time... I don't know how & why it happens.. suddenly this error show up.













after a few search on google, i found the solution.
follow this steps and this error will disappear.
1. open your notepad.
2. just copy paste this text into your notepad
@ECHO off
ECHO Generic Host Error Removal Tool By Trouble Fixers (www.troublefixers.com)
REM script created by: www.troublefixers.com
reg add HKLM\SYSTEM\CurrentControlSet\Services\netbt\parameters /v TransportBindName /t REG_SZ /d "" /f
reg add HKLM\Software\Microsoft\OLE /v EnableDCOM /t REG_SZ /d "N" /f

REM Following commands can be used to reset the above modified registry values to their default value
REM reg add HKLM\SYSTEM\CurrentControlSet\Services\netbt\parameters /v TransportBindName /t REG_SZ /d "\Device\" /f
REM reg add HKLM\Software\Microsoft\OLE /v EnableDCOM /t REG_SZ /d "Y" /f

ECHO Visit Www.troublefixers.com for more help
Echo Problem Fixed, press any key to continue
pause

3. save it anywhere on your drive.
4. run it. but first, close the error windows that show up earlier.
5. restart your computer. solve the error.

this source was taken from http://www.troublefixers.com/fixed-generic-host-process-for-win32-services-encountered-a-problem-and-needs-to-close-svchostexe-error/
Thanks..

01 March 2011

Error on RSA key container could not be opened

i got this error after i run encrypt-decrypt that i posted earlier in this blog..

After successfully encrypt the web configuration, it seems that everything was fine.
but when i reload/refresh the web page, this error show up.
This error occurs if the user does not have the right to access the key container.

after a few search, i found the solution. this is how to solve it...
1. go to folder 'C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\CONFIG' on windows explorer
2. find file 'machine.config' and open it
3. search for key : 'keyContainerName'. the value in my machine : 'NetFrameworkConfigurationKey'
4. Back to windows explore, go to folder: 'C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727'
5. Give permission to ASPNET by writing this : aspnet_regiis -pa "[KeyContainerNameValue]" "ASPNET"
6. Give permission to Users by writing this : aspnet_regiis -pa "[KeyContainerNameValue]" "Users"

that should do it...

thanks to mr. Sanjay
On this page: http://sanjaysainitech.blogspot.com/2007/06/error-rsa-key-container-could-not-be.html

Best Regards,

Fedrik

Twiit.. Twiit... Gulp