View Single Post
  #16   Report Post  
Posted to microsoft.public.excel.programming,microsoft.public.vb.general.discussion
Rick Rothstein \(MVP - VB\)[_1587_] Rick Rothstein \(MVP - VB\)[_1587_] is offline
external usenet poster
 
Posts: 1
Default Excel columns: Converting numbers to letters and vice versa

So, has the question you asked in **this** thread been resolved yet?

Rick


"Jack" <replyto@it wrote in message
...
Sorry, it supposed to be a reply to the other thread.
Jack

"Rick Rothstein (MVP - VB)" wrote in
message ...
Which reference did your remove and then add back in again? In one of
your previous responses, you said you needed to be able to convert the
letters to their numerical equivalent without being connected to Excel;
that is, you said you needed a general solution. What reference is
associated with the "general solution" you sought?

For your stated general solution, did you look at the ToNumber function I
posted in a previous response in this thread? While I admit this function
handles much, much more than you need to for your application, I would
point out that there is no time penalty in using it for the range of
letters you are interested it (the function only loops as many times as
there are letters in the argument passed into it).

Rick


"Jack" <replyto@it wrote in message
...
Problem solved.
Just removed the reference, saved the project, restarted the project and
added again the same reference.
Any thoughts on that?
Jack

"Jack" <replyto@it wrote in message
...
Hello,
My app is using Excel spreadsheet.
User has a choice of preselecting some of the sheet's columns.
Now:
Excel is using letters as the visual indexing, of the columns but when
programming the corresponding number (A --1, B --2..., AA--28,
AB--29 etc) must be used..

What will be the best method of converting those letters into numbers?
Jack