Re: Address can not be more than 30 characters



Its a macro. Put in a module and execute from there.

If you're new to macros, you may want to read David McRitchie's intro at:
http://www.mvps.org/dmcritchie/excel/getstarted.htm

--
Don Guillett
Microsoft MVP Excel
SalesAid Software
dguillett1@xxxxxxxxxxxxx
"NeSchw6G" <NeSchw6G@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message news:9C8F636B-0BAD-4FBA-8CF8-7999E7B8B9C8@xxxxxxxxxxxxxxxx
Don, It looks like you have a good idea except that I have no idea what "Sub
limitcol()" means, so I don't know how to execute this. Can you simplify for
me?

Thank you!

"Don Guillett" wrote:

Sub limitcol()
mc = "J"
On Error Resume Next
lr = Cells(Rows.Count, mc).End(xlUp).Row
For Each c In Range(Cells(1, mc), Cells(lr, mc))
c.Offset(, 1) = Right(c, Len(c) - 30)
c.Value = Left(c, 30)
Next c
End Sub

--
Don Guillett
Microsoft MVP Excel
SalesAid Software
dguillett1@xxxxxxxxxxxxx
"NeSchw6G" <NeSchw6G@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
news:56D40342-C95F-40A9-8708-776FDDB23E86@xxxxxxxxxxxxxxxx
> Hello,
> I have a report that is opened through excel and it includes an address
> column. I am sending this report to a thrid party who can not have the
> address field be more than 30 characters. Is there a formula that > would
> recognize if the field is more than 30 characters and then move the > extra
> characters to the next column? the report includes over 1,000 records > so
> it
> would be nice if I did not have to do any manual work.
>
> Thank you,



.



Relevant Pages

  • RE: Convert Macro to run in 2007
    ... I would help if you would tell us what this macro is supposed to accomplish. ... if one of the lines scaned was greater than 80 characters, ... Dim oDoc As Document ... ' If the report has lines greater than 80 columns with format characters ...
    (microsoft.public.word.vba.general)
  • Need help copying 3 range data and insert into form
    ... I am trying to write a macro In Word 2003. ... (access no., Narrative, Report no.) ... I want to read a range in line 2 6 characters in length. ... I know if I create 3 separate range ...
    (microsoft.public.vb.general.discussion)
  • Need help inserting range data from Report doc to Form
    ... I am trying to write a macro In Word 2003. ... (access no., Narrative, Report no.) ... I want to read a range in line 2 6 characters in length. ... I know if I create 3 separate range ...
    (microsoft.public.word.vba.general)
  • Re: replace all ^p s unless followed by a date
    ... I created a macro with the code "msgbox asc" to ... and am having trouble getting rid of extra ^p characters. ... Set wdApp = CreateObject ... .Execute Replace:=wdReplaceAll ...
    (microsoft.public.word.vba.general)
  • Re: Utilize a table to tell where to email specified reports
    ... If you already have written a macro which sends email and you like how it ... execute that macro (execute it automatically from within VBA). ... report (and likewise you can also change which report it is that they get ...
    (microsoft.public.access.modulesdaovba)