Czetsuya (czetsuya) uses Bloggers to connect with peer Bloggers. Sign up to follow Czetsuya (czetsuya) and promote your blogs now!

Czetsuya

Activities of Czetsuya

Feb 6, 2012
Czetsuya posted a new topic.
2

Elmah not logging, elmah.axd page is always null when using SqlErrorLog

czetsuya's tech ― First make sure that you're web.config file is setup properly and that you have defined elmah to handle the error in each controller. You can do that easily in c# mvc3 by using nuget and downloading elmah, elmah.corelibrary and elmah.contrib.mvc.... (More)
Posted 4 days ago
Jan 30, 2012
Czetsuya posted a new topic.
3

How to read and write an object in a textfile in C#

czetsuya's tech ― Long time ago I've a requirement to read sms messages from device to be written in a text file. Before I learned to serialize an object, I was saving it in a file comma-delimited. That approach is working but sometimes it's a pain to keep track of... (More)
Posted 12 days ago
Jan 26, 2012
Czetsuya posted a new topic.
3

Read and update your mailbox using php

czetsuya's tech ― There are 2 ways I use 2 read email from my mailbox. Let the code explain:1.) Usually use for gmail./* connect to gmail */$hostname = '{imap.gmail.com:993/imap/ssl}INBOX';$username = 'xxx@gmail.com';$password = 'xxx';/* try to connect */$inbox =... (More)
Posted 15 days ago
Czetsuya posted a new topic.
3

Injection of Control in a C# Console Application

czetsuya's tech ― Now that I'm working with C# MVC3, I learned that it's easier to setup Injection of Control because of several available plugins that you can use straightly after install. For example the one I'm using is Unity.MVC, in Visual Studio 2010 you just... (More)
Posted 15 days ago
Jan 24, 2012
Czetsuya posted a new topic.
3

How to alter bit and date column's default value in MSSQL

czetsuya's tech ― Aside from using the SQL Designer, you can alter a bit and date column's default value.ALTER TABLE TableName ADD CONSTRAINT TableName_Disabled DEFAULT 0 FOR DisabledALTER TABLE TableName ADD CONSTRAINT TableName_DateCreated DEFAULT getdate() FOR... (More)
Posted 18 days ago
Jan 16, 2012
Czetsuya posted a new topic.
4

Add a jquery datepicker on jquery dialog box via load method

czetsuya's tech ― Recently I've worked on a form that requires a jquery datepicker to be rendered inside jquery's dialog element. Where I encountered several problems like:1.) datepicker() should be invoke inside dialog2.) the dialog created (div) should be remove... (More)
Posted 26 days ago
Jan 11, 2012
Czetsuya posted a new topic.
5

Many to many relationship in Entity Framework

czetsuya's tech ― An example of many-to-many relationship is asp's membership tables, between aspnet_Users and aspnet_Roles.Usually we declare it like this:public class AspUser { public Guid UserId { get; set; } ... public ICollection AspRoles { get; set; }}public... (More)
Posted on Jan 11th, 2012
Czetsuya posted a new topic.
6

Specify ON DELETE NO ACTION or ON UPDATE NO ACTION, or modify other FOREIGN KEY constraints

czetsuya's tech ― Have you encountered this error:"Introducing FOREIGN KEY constraint 'x_y_Target' on table 'z_UsersInRoles' may cause cycles or multiple cascade paths. Specify ON DELETE NO ACTION or ON UPDATE NO ACTION, or modify other FOREIGN KEY constraints."It... (More)
Posted on Jan 11th, 2012
Czetsuya posted a new topic.
4

How to declare foreign key in Entity Framework

czetsuya's tech ― There are 2 ways to declare foreign key in entity framework. Assuming we have 2 entities aspnet_Users and Person, which are link via UserId from aspnet_Users.1.) class Person { public Guid UserId { get;set; } [ForeignKey("UserId")] public virtual... (More)
Posted on Jan 11th, 2012
Jan 4, 2012
Czetsuya posted a new topic.
7

Adding loading screen to C# MVC ajax dialog form using jquery

czetsuya's tech ― With my experience from telerik, I want my entity's add and edit form to be a popup so I don't have to change screen. I'm using C# MVC3, so I tried to look for jquery add on that would do the job. Fortunately I've come up with this article: http:/... (More)
Posted on Jan 4th, 2012
Dec 28, 2011
Czetsuya posted a new topic.
7

validation-summary-errors div showing even if there is no error binded to a property

czetsuya's tech ― I'm working on a change password form when I encountered this strange behavior from mvc3. I created a simple form and change password model with 3 fields (old, new, confirm password). Then I extended ValidationAttribute to validate the password's... (More)
Posted on Dec 28th, 2011
Dec 20, 2011
Czetsuya posted a new topic.
8

Executing a linq query with a bridge table like aspnet_Users and aspnet_Roles

czetsuya's tech ― Using model first approach, we add aspnet_Users, aspnet_Roles and aspnet_UsersInRoles in the edmx file. But why is aspnet_UsersInRoles missing? It's because aspnet_Users has one-to-many relationship to aspnet_Roles. To get the role of the user, we... (More)
Posted on Dec 20th, 2011
Dec 17, 2011
Czetsuya posted a new topic.
9

Calling MSSQL's aspnet_Membership_CreateUser stored procedure

czetsuya's tech ― Here's how you would want to call mssql's aspnet_Membership_CreateUser method:DECLARE @return_value int, @UserId uniqueidentifier, @nowUtc datetime, @now datetime set @nowUtc = getutcdate() set @now = getdate()EXEC @return_value = [dbo].... (More)
Posted on Dec 17th, 2011
Dec 16, 2011
Czetsuya posted a new topic.
7

How to enable jquery's lavalamp's links

czetsuya's tech ― I've used lavalamp's menu in my project several times and have experienced the same problem 2 or 3 times after copying the code from the downloadable zipped file. It's as if the links were not there and even you click the menulink the page will not... (More)
Posted on Dec 16th, 2011
Dec 6, 2011
Czetsuya posted a new topic.
10

The 'System.Web.Security.SqlMembershipProvider' requires a database schema compatible with schema version '1'.

czetsuya's tech ― Normally you will encounter this issue if you generate an sql script of an aspnet_database without including the data. To resolve this you have 2 options:1.) Execute c:windowsmicrosoft.net ramework 4.xxxspnet_regsql.exe, and just follow through.2.)... (More)
Posted on Dec 6th, 2011
Dec 2, 2011
Czetsuya posted a new topic.
7

Create a Magento extension that will only allow a customer to login until a given expiry time

czetsuya's tech ― Long time ago I was assigned to modify magento, add an expiry date and check if the costumer is expired during login. Those times resource were scarce and what I did was hacked magento, add custom codes and fields in the database. Which is not a good... (More)
Create a Magento extension that will only allow a customer to login until a given expiry time
Posted on Dec 2nd, 2011
Dec 1, 2011
Czetsuya posted a new topic.
9

How to download a zipped file of a magento extension

czetsuya's tech ― There are times when you want to see the code behind of a magento extension, but using magento connect would not give you all the files that have been created. To do that simply go to url below and type the Magento Connect 1 extension key:http:/... (More)
Posted on Dec 1st, 2011
Nov 30, 2011
Czetsuya posted a new topic.
12

How to install and setup magento on a windows 7 machine

czetsuya's tech ― This tutorial will try to install and setup magento on a local pc running windows 7. Requirements (I'm using the following versions, you can search the download links using google - lame :-) ):1.) apache2.22.) php-5.2.143.) MySQL Server 5.54.)... (More)
Posted on Nov 30th, 2011
Nov 16, 2011
Czetsuya posted a new topic.
13

How to setup elmah for MVC3 .NET 4.0

czetsuya's tech ― Tired of setting up your configuration to load elmah? You think you already configured everything even compiling the source code to build on .net 4.0 but still failed?Experience a routing error, or this persistent line:elmah Could not load file or... (More)
How to setup elmah for MVC3 .NET 4.0
Posted on Nov 16th, 2011
Nov 12, 2011
Czetsuya posted a new topic.
10

Passing an array of objects to mssql stored procedure

czetsuya's tech ― Oftentimes you need to pass an array of objects (could be ids, types, etc) in an mssql stored procedure that you either need to insert into a table or use as filter. The following codes will explain the latter:Pass an array of integers:ALTER... (More)
Posted on Nov 12th, 2011
Nov 11, 2011
Czetsuya posted a new topic.
14

Setup CruiseControl.NET with Collabnet Edge

czetsuya's tech ― Recently I was searching for a Continuous Build Integration software for dotnet like what Jenkins do for java and I've found CruiseControl.NET (http://confluence.public.thoughtworks.org/display/CCNET).I've worked with my environment setup:-Windows 7... (More)
Setup CruiseControl.NET with Collabnet Edge
Posted on Nov 11th, 2011
Nov 7, 2011
Czetsuya posted a new topic.
10

Insert an md5 password in mssql

czetsuya's tech ― To md5 a string in mssql we execute this query:select HASHBYTES('MD5', 'password')//But this has a problem because it returns a VarBinary data type which is a garbled text. So it should be converted first to NVarchar:SELECT CONVERT(NVARCHAR(32)... (More)
Posted on Nov 7th, 2011
Nov 6, 2011
Czetsuya posted a new topic.
12

How to activate maven profile inside eclipse

czetsuya's tech ― Normally maven is use for project dependency management and lifecycle, so there are several developers working on it. Each has its own development environment either in windows, linux or mac.To do this we create several profiles for each developer in... (More)
How to activate maven profile inside eclipse
Posted on Nov 6th, 2011
Nov 3, 2011
Czetsuya posted a new topic.
18

How to use EntityFramework CodeFirst to update your database

czetsuya's tech ― This tutorial will attempt to explain how to update an already existing database using EntityFramework's CodeFirst approach.We need:1.) VS2010 SP12.) NuGet3.) EntityFramework 4.14.) EntityFramework.Migrations Steps:1.) We need to make sure that we... (More)
How to use EntityFramework CodeFirst to update your database
Posted on Nov 3rd, 2011
Oct 26, 2011
Czetsuya posted a new topic.
18

Things to remember in creating jbpm with seam

czetsuya's tech ― This writing will reference the TODO example from seam:http://docs.jboss.org/seam/latest/reference/en-US/html/tutorial.html#registration-exampleNote that I used seam-gen to generate the project.File you should have:+views +login.xhtml +todo.xhtml... (More)
Posted on Oct 26th, 2011
Oct 25, 2011
Czetsuya posted a new topic.
13

Useful tools when building a j2ee project

czetsuya's tech ― Below are the tools I commonly use when setting up my eclipse and before creating a new project.JBoss Tools - http://download.jboss.org/jbosstools/updates/nightly/trunk/TestNG - http://beust.com/eclipseFindBugs - http://findbugs.cs.umd.edu/eclipse... (More)
Posted on Oct 25th, 2011
Oct 18, 2011
Czetsuya posted a new topic.
21

The length of the query string for this request exceeds the configured maxQueryStringLength value. firefox

czetsuya's tech ― Problem:Unrecognized configuration section httpRuntime.The length of the query string for this request exceeds the configured maxQueryStringLength value. firefoxIn case you experience the same error, it's because of the new feature available for mvc3... (More)
Posted on Oct 18th, 2011
Sep 20, 2011
Czetsuya posted a new topic.
18

How to use m:classifier in apache ivy for dependency management

czetsuya's tech ― Recently I've been working on a web service client project that uses apache axis2. And we use ivy for dependency management. Axis2 depends on several jars and one of them is mex, which could be located here:http://mvnrepository.com/artifact/org... (More)
Posted on Sep 20th, 2011
Sep 8, 2011
Czetsuya posted a new topic.
14

Failed to load javax.xml.soap.MetaFactory: org.jboss.ws.core.soap.SAAJMetaFactoryImpl

czetsuya's tech ― To resolve this issue simply download and copy jbossws-client.jar in %JBOSS_HOME%/server/default/lib folder. (More)
Posted on Sep 8th, 2011
Sep 5, 2011
Czetsuya posted a new topic.
7

How to use PMD with eclipse

czetsuya's tech ― This tutorial will explain how to use PMD (http://pmd.sourceforge.net/) with eclipse.What you need:1.) eclipse-java-helios2.) PMD (download the latest version here: http://pmd.sourceforge.net/). Extract in c:javaa.) From here you can download a... (More)
Posted on Sep 5th, 2011

Bloggers Spotlight

Rhea Bue

19 Votes | 4 Comments | 10 Followers

Paolo

75 Votes | 23 Comments | 31 Followers

Sonia

174 Votes | 83 Comments | 115 Followers

Manoj

283 Votes | 124 Comments | 122 Followers

Spirituality Ireland

20 Votes | 3 Comments | 12 Followers

Sugar

27 Votes | 5 Comments | 7 Followers

TechNonStop

23 Votes | 3 Comments | 13 Followers

Kirsty

15 Votes | 3 Comments | 5 Followers