View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
agarwaldvk[_16_] agarwaldvk[_16_] is offline
external usenet poster
 
Posts: 1
Default Q. Autofill question: Can I autofill alpha characters like I can numbers?

Hopefully, this should help!

From what I know, this can't be done from the frontend worksheets bu
you can do it programmatically using VBA. Have a look at this :-

Sub test()
Dim cnt As Integer, tempval As Integer, final As Integer
cnt = 1
final = 26
tempval = 65 'for upper case A
Do While cnt <= final
Cells(cnt, 1).Value = Chr(tempval)
tempval = tempval + 1
cnt = cnt + 1
Loop
End Sub

The output is letters A through to Z in the first column in rows
through to row 26.


Best regards


Deepak Agarwa

--
Message posted from http://www.ExcelForum.com