Although the CPU will physically fit a LGA 1150 socket, the BIOS version of your system may not run it for two reasons.
1. The computer and motherboard predates the Haswell-refresh release, so there may be no support for any Haswell-refresh CPU.
2. Prebuilt computers often have significant restrictions on the upgrages they will support.
Are you sure you have a LGA 1150 socket? I was under the impression that system was LGA 1155. (i3 2120)
If you are replacing and i3 with an i5, there may be heat and power issues too. The new CPU has a higher TDP and if you plan to overclock, a lot higher, and will generate a lot more heat.