(ERROR) Microsoft Visual Basic: 400

G

Guest

Hello, Im running a macro and I get a mesage:

Microsoft Visual Basic:
X 400
Accept / Help

I click help and I get nothing... does anyone know what it is about?

thanks!
 
B

Bob Phillips

Post the code.

--
HTH

Bob Phillips

(replace somewhere in email address with gmail if mailing direct)
 
G

Guest

Hello thanks... I found the mistake already, anyways the code is:

Option Explicit
Sub Curva_S()
Columns("B:IV").Select
Selection.Delete Shift:=xlToLeft
Dim LastCol As Long
With ActiveSheet
LastCol = .Range("a5").Value
Range("a1", .Cells(4, LastCol)).FillRight
End With
Rows("2:2").Select
With Selection
.HorizontalAlignment = xlCenter
.VerticalAlignment = xlBottom
.WrapText = False
.Orientation = 0
.AddIndent = False
.IndentLevel = 0
.ShrinkToFit = False
.ReadingOrder = xlContext
.MergeCells = False
End With
Rows("2:2").Select
Selection.Columns.autofit
End Sub

Before "End Sub" I had a "run application..." which I deleted and now it
works (the applications was a macro which changed)...

Thanks again to those that have helped me get this codes!
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top