You could try the .NET library Proj.Net. See the Loading a projection by Spatial Reference ID page for how to add in the GB National Grid.
Example code from this forum post:
CoordinateSystemFactory c = new CoordinateSystemFactory();
ICoordinateSystem target = c.CreateFromWkt("PROJCS[\"OSGB 1936 / British National Grid\",GEOGCS[\"OSGB 1936\",DATUM[\"OSGB_1936\",SPHEROID[\"Airy 1830\",6377563.396,299.3249646,AUTHORITY[\"EPSG\",\"7001\"]],AUTHORITY[\"EPSG\",\"6277\"]],PRIMEM[\"Greenwich\",0,AUTHORITY[\"EPSG\",\"8901\"]],UNIT[\"degree\",0.01745329251994328,AUTHORITY[\"EPSG\",\"9122\"]],AUTHORITY[\"EPSG\",\"4277\"]],PROJECTION[\"Transverse_Mercator\"],PARAMETER[\"latitude_of_origin\",49],PARAMETER[\"central_meridian\",-2],PARAMETER[\"scale_factor\",0.9996012717],PARAMETER[\"false_easting\",400000],PARAMETER[\"false_northing\",-100000],UNIT[\"metre\",1,AUTHORITY[\"EPSG\",\"9001\"]],AUTHORITY[\"EPSG\",\"27700\"]]");
ICoordinateSystem source = c.CreateFromWkt("GEOGCS[\"GCS_WGS_1984\",DATUM[\"D_WGS_1984\",SPHEROID[\"WGS_1984\",6378137,298.257223563]],PRIMEM[\"Greenwich\",0],UNIT[\"Degree\",0.0174532925199433]]");
CoordinateTransformationFactory trf = new CoordinateTransformationFactory();
ICoordinateTransformation tr = trf.CreateFromCoordinateSystems(source, target);
double[] point = new double[] {-4.0, 55.6};
double[] result = tr.MathTransform.Transform(point);
Console.WriteLine(result);
Alternatively the Ordnance Survey have a downloadable tool if you register at http://gps.ordnancesurvey.co.uk/convert.asp
If your starting datum is OSGB 1936 (EPSG:27700) I don't think you'll be able to use Proj.Net for your conversion. Looking at other people's code on the Discussions page, it looks like Proj.Net is just applying a simple datum shift based on the "TOWGS84" parameter. This parameter is set in the Well Known Text (WKT) of your starting datum. A "TOWGS84" parameter will exist in the WKT only if you can do a simple transformation from your starting datum to WGS84.
Getting from OSGB1936 -> WGS84 is a two-step process where you have to convert OSGB1936 to ETRS89, then from ETRS89 to WGS84. (see EPSG:1681)
You would think you should be able to take the British National Grid, manipulate the XYs by some value, and get the Web Mercator XYs, but the math just isn't that simple.
Best Answer
The OSGB_1936_To_WGS_1984_Petroleum has a listed accuracy of around 2m. We have a significantly larger accuracy value for OSGB_1936_To_WGS_1984_NGA_7PAR. It was published by NGA (was NIMA was DMA). The transformation parameters can be found in the Geotrans software, but there's no accuracy information. Esri added it for interoperability because it's in Geotrans.