I am trying to create a function which will give me alphabet position when an index is passed. It will be same like how excel shows it\'s columns. A...Z, AA,AB.... I wrote t
static string GetColumnName(int index)
{
const int alphabetsCount = 26;
string result = '';
if (index >= alphabetsCount)
{
result += GetColumnName(index-alphabetsCount)
}
return (string) (64 + index);
}
My C# is HORRIBLE AND RUSTY. Interpret this as pseudocode - it will almost certainly not compile, but may get you started.