 <p>Assuming you have interop, it would be like the below. Note <code>xlValidateWholeNumber</code>, that can be changed to <code>xlValidateDecimal</code> (and the subsequent Formula1 below would need to be a decimal) for decimals).</p> <pre><code>private void SetValidationBetweenNumbers() { Microsoft.Office.Tools.Excel.NamedRange cellThatNeedsValidating = this.Controls.AddNamedRange(this.Range[""A1"", missing], "cellThatNeedsValidating"); cellThatNeedsValidating.Validation.Add( Excel.XlDVType.xlValidateWholeNumber, Excel.XlDVAlertStyle.xlValidAlertStop, Excel.XlFormatConditionOperator.xlBetween, "1", "=B1"); } </code></pre>