![]() |
split cell content without using a specific character/sign
Roger,
One way:- Sub Test() Dim intA As Integer, strB As String Dim strC As String, Var Var = ActiveCell.Value ' (or whatever) intA = Left(Var, 2) strB = Mid(Var, 3, 1) strC = Right(Var, 1) End Sub This only works if the format of the target is always the same. regards' Don -- "Roger" wrote in message om... Hi All, I have an issue with how to split cell content without using a specific character/sign. Eg The content of a cell is 13GR. The searched result after the splitting of the cell content shall be: intA= 13 strB = G strC = R How should the code be written to solve the issue? I would be very grateful for help. Roger |
All times are GMT +1. The time now is 08:52 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com