Tuesday, July 23, 2013

The type 'System.Data.Entity.DbContext' is defined in an assembly that is not referenced. You must add a reference to assembly 'EntityFramework, Version=4.4.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089'.

Dear Readers,

I face subjected problem while trying to learn ADO.Net Entity Framework in visual studio. After a bit of searching, I come to know that I have not included EntityFramework.dll reference in my project. Just add the DLL reference and I hope that your will out of this problem.

Please note that in case if you don't find EntityFramework.dll in references then you can locate it in the project bin (Debug\Release) folder where you add ADO.Net Entity Data Model.

I hope that this will work for you as it worked for me. So please leave a comment if this post help you so other visitors can also trust on this solution.

Thanks.



Sunday, January 27, 2013

Saving changes is not permitted. The changes you have made require the following tables to be dropped and re-created. You have either made changes to a table that can't be re-created or enabled the option Prevent saving changes that require the table to be re-created

 You receive this message in SQL Server 2008 when you alter a table and after modification in table, you want to save this modification.

To allow saving the modification they suggested that first drop the table and then recreate it which is not suitable when you have important data/information, and it also causes increase in rework.

To save yourself from this rework, we have another way which is mentioned below.

Step 1:- Open your SQL Server Management Studio.

Step 2:- Goto Tools -> Options -> Designers.

Step 3:- Uncheck checkbox "Prevent saving changes that require table re-creation".

Step 4:- Save your changes.

Now, attempt to save your modification changes which you have done in your table.

I hope that this will work for you as it worked for me. So please leave a comment if this post help you so other visitors can also trust on this solution.

Thanks.

Friday, October 19, 2012

ORA-38104: Columns referenced in the ON Clause cannot be updated

In my case, this error pertains to Oracle Merge query. After 30 minutes of time wastage and a lot of hunting on different forums, I come to know that where and why was my merge query throwing exception.

I was giving multiple criteria in ON clause of merge query, and was also trying to update a column which I have mentioned in ON clause. Once I remove that column from update clause of merge query, it executed successfully.

I hope that this will also works for you.

In case if this post help you, then please comment on it.

Thanks.

uncaught TypeError: Property href of object is not a function

Dear Readers,

I face this problem in a web application build in .aspx. It mainly occurs when you are performing some action with javascripting or Jquery. In my case, I was using javascript. It was working fine in IE (Internet Explorer) but was unable to perform any action in chrome.

If you read subjected error message carefully, it tells you that you are accessing an object as function which is not a function at all.

In my case, I mistakenly access window.href as a function. for example, I wrote it as

window.href('www.google.com');

which is wrong and that is why it was not functioning properly in chrome. The correct method is

window.href= 'www.google.com';

I hope that after reading my post, you will able to understand that where you are doing mistake and correct it.

If this post help you then post your comments so that others can also consider this as a worth information.

Thanks.

Tuesday, August 7, 2012

Could not find any resources appropriate for the specified culture or the neutral culture. Make sure resources was correctly embedded or linked into assembly at compile time, or that all the satellite assemblies required are loadable and fully signed.

I have some images on button and icons on form and the above message display whenever there is any image try to assign to a button or icon to a form. I have wasted my one day just to find out what I made wrong with my desktop application during uploading it on Visual Source Safe and was amazed when I found it. During this time, I read solutions on different sites and blogs which I am writing below but this does not resolve the issue.

1) Check Project Namespace by going to properties of project. (Right click on project and select properties)

2) Resources.resx file in Properties folder of project might not contain same name which you mentioned in project namespace.

3) Remove all files from "bin" folder inside project and re-build your project again.

All methods I tried, but of no use.... Then I find out that I include following two folders which were excluded from project and these were

1) Bin
2) Obj

out of that when I again exclude obj folder from my project. It start work fine. This solution worked for me and I hope that it will also help you.

If this solution help you then please write your comments so that other find it as a valuable content.

Thanks.

Sunday, March 25, 2012

wamp server turn to yellow color

When I install wamp sever on my laptop, I face subjected problem. The wamp server turns to yellow instead of green. To fix it follow below mentioned steps:

1) Stop IIS Server (type inetmgr.exe in run command)
2) Locate httpd.config file (default path is C:\wamp\bin\apache\Apache2.2.21\conf)
3) Locate below lines
#Listen 12.34.56.78:80
Listen 80

and change them with
#Listen 12.34.56.78:8080
Listen 8080.

Save httpd.config file and restart wamp services. You can see that it will be now changed into green color.

Please comment if this post is helpful for you.

Wednesday, February 1, 2012

Cannot use the special principal 'sa'. (Microsoft SQL Server, Error: 15405)

Yesterday, I start SQL Server 2005 and try to connect with sa user but was enable to connect with the 'sa' user and got this error:

Cannot use the special principal 'sa' (Microsoft SQL Server, Error: 15405)

After doing some google, I found out the solution which I am sharing so that others can get all the possible solutions from this article.

The titled message mean that your sa user is disabled. To enable it, you have to follow below mentioned steps:

1) you have to change the authentication mode: go to Management Studio and open Object Explorer. Connect to your server and right-click on the server name, then select Properties. Go to Security tab and under Server Authentication select "SQL Server and Windows Authentication Mode".

2) Also, after you follow the directions above, you will also need to explicitly enable the sa account as well. Go to Security->Logins. Right-click on the "sa" account, select "Properties". In the list on the left, select "Status" and under "Login" on the right, make sure "Enable" is selected.

3) exec sp_changedbowner 'sa','true' in query editor after selecting the database whom you want to assign user sa.

4) You can also change the password of sa (it's better to change the password).

After performing all above mentioned changes, Exit with SQL Management Studio. Restart Sql Service from services.msc.

Open Management Studio again and try to login "sa". Hopefully, it works. Enjoy!

(Please comment if it work for you).

Docker Tutorial

 I have listed all the necessary commands of Docker below. In case if any is missing or if any improvement required, please share in comment...