The Index property of DataGridViewColumn class can be used for the above purpose like
dgv.Columns["A"].Index.ToString();
[Edit]
To get index of the Column from ColumnHeaderText[/Edit]
string headerText = "A";
string index = string.Empty;
foreach (DataGridViewColumn column in dgv.Columns)
if (column.HeaderText.Equals(headerText, StringComparison.InvariantCultureIgnoreCase)){
index = column.Index.ToString();
break;
}