In this paper, we report the formation and superconductivity of quaternary intermetallic system Yni2B2Cx with ThCr2Si2-type structure. Samples prepared by arc-melting crystallize in single phase of the composition of YNi2B2Cx when x=0.9—1.2 while the secondary unknown phases increase obviously when x<0.8 or x>1.2. Superconducting-transition temperature Tc determined by the tem,perature dependence of magnetization displays two steps with increasing carbon concentration: Tc≈12.5K for x≤0.8, Tx≈15K for x≥0.9.