×
INTELLIGENT WORK FORUMS
FOR ENGINEERING PROFESSIONALS

Log In

Come Join Us!

Are you an
Engineering professional?
Join Eng-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!

*Eng-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

Run-time error '1004'

Run-time error '1004'

Run-time error '1004'

(OP)
kool_kix (Visitor) May 22, 2002
I'm getting the following error.

"Run-time error '1004': Unable to set the CenterFooter property of the PageSetup class"

prntaSheet.Activate
prntaSheet.PageSetup.CenterFooter = "STYLE 1 : " & estsrcSheet.Cells(5, 1).Value & ", " & estsrcSheet.Cells(7, 1).Value & ", " & estsrcSheet.Cells(9, 1).Value & ", " & estsrcSheet.Cells(11, 1).Value & ", " & estsrcSheet.Cells(13, 1).Value
If estsrcSheet.Cells(5, 10).Value = "yes" Then
    prntaSheet.PageSetup.CenterFooter = prntaSheet.PageSetup.CenterFooter & Chr(10) & "STYLE 2 : " & estsrcSheet.Cells(5, 2).Value & ", " & estsrcSheet.Cells(7, 2).Value & ", " & estsrcSheet.Cells(9, 2).Value & ", " & estsrcSheet.Cells(11, 2).Value & ", " & estsrcSheet.Cells(13, 2).Value
End If
If estsrcSheet.Cells(6, 10).Value = "yes" Then
    prntaSheet.PageSetup.CenterFooter = prntaSheet.PageSetup.CenterFooter & Chr(10) & "STYLE 3 : " & estsrcSheet.Cells(5, 3).Value & ", " & estsrcSheet.Cells(7, 3).Value & ", " & estsrcSheet.Cells(9, 3).Value & ", " & estsrcSheet.Cells(11, 3).Value & ", " & estsrcSheet.Cells(13, 3).Value
End If
prntaSheet.Activate
'-------------------------
'ERROR OCURRS ON NEXT LINE
'-------------------------
prntaSheet.PageSetup.CenterFooter = prntaSheet.PageSetup.CenterFooter & Chr(10) & Chr(10) & "Bid Provided By : Art's Custom Cabinets, Inc. - (559) 562-2766"
prntaSheet.PageSetup.LeftFooter = estnumLabel.Caption

prntcSheet.Activate
With ActiveSheet.PageSetup
    .CenterFooter = "STYLE 1 : " & estsrcSheet.Cells(5, 1).Value & ", " & estsrcSheet.Cells(7, 1).Value & ", " & estsrcSheet.Cells(9, 1).Value & ", " & estsrcSheet.Cells(11, 1).Value & ", " & estsrcSheet.Cells(13, 1).Value
    If estsrcSheet.Cells(5, 10).Value = "yes" Then
        .CenterFooter = ActiveSheet.PageSetup.CenterFooter & Chr(10) & "STYLE 2 : " & estsrcSheet.Cells(5, 2).Value & ", " & estsrcSheet.Cells(7, 2).Value & ", " & estsrcSheet.Cells(9, 2).Value & ", " & estsrcSheet.Cells(11, 2).Value & ", " & estsrcSheet.Cells(13, 2).Value
    End If
    If estsrcSheet.Cells(6, 10).Value = "yes" Then
        .CenterFooter = ActiveSheet.PageSetup.CenterFooter & Chr(10) & "STYLE 3 : " & estsrcSheet.Cells(5, 3).Value & ", " & estsrcSheet.Cells(7, 3).Value & ", " & estsrcSheet.Cells(9, 3).Value & ", " & estsrcSheet.Cells(11, 3).Value & ", " & estsrcSheet.Cells(13, 3).Value
    End If
'-------------------------
'ERROR OCURRS ON NEXT LINE
'-------------------------
    .CenterFooter = ActiveSheet.PageSetup.CenterFooter & Chr(10) & Chr(10) & "Bid Provided By : Art's Custom Cabinets, Inc. - (559) 562-2766"
    .LeftFooter = estnumLabel.Caption
End With

RE: Run-time error '1004'

kool_kix,

The Center Footer allows a maximum of 253 characters (by my test procedure).  You must be exceeding this limit.  Sorry.  

Regards,
M. Smith

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Eng-Tips Forums free from inappropriate posts.
The Eng-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Eng-Tips forums is a member-only feature.

Click Here to join Eng-Tips and talk with other members! Already a Member? Login



News


Close Box

Join Eng-Tips® Today!

Join your peers on the Internet's largest technical engineering professional community.
It's easy to join and it's free.

Here's Why Members Love Eng-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close