+ Reply to Thread
Results 1 to 2 of 2

1004 (Unable to set LineStyle prperty of the Border class)

  1. #1
    Forum Contributor
    Join Date
    06-21-2013
    Location
    Chicago, IL
    MS-Off Ver
    Excel 2010
    Posts
    179

    1004 (Unable to set LineStyle prperty of the Border class)

    Gurus,

    I am not sure why this error has popped up. The code worked before I put in call statements to unprotect the worksheet, then protect the worksheet once it was complete. Even so, the range AJ52:AL52 is not even locked. It must be something simple that I am missing.

    FYI, I tried the code with and without a (with - end with) statement. It errors out both ways.

    The code errors out at .Linestyle = xlNone

    Please Login or Register  to view this content.
    Here is a copy of my untest (unlock) and lockform code
    Please Login or Register  to view this content.
    Please Login or Register  to view this content.
    TIA,
    Tim
    Last edited by TimlmiT; 10-10-2014 at 10:11 AM.

  2. #2
    Forum Contributor
    Join Date
    06-21-2013
    Location
    Chicago, IL
    MS-Off Ver
    Excel 2010
    Posts
    179

    Re: 1004 (Unable to set LineStyle prperty of the Border class)

    My apologies.

    I found the error. I had another call statement to unlock and lock the form in another part of the code when "sample" was changed. Therefore, the form was locked before the .lineStyle code could be executed.

    I knew it had to be something I was over looking.

    Tim

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. [SOLVED] 1004 (unable to get the weeknum property of the worksheetfunction class)
    By rayexcel in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 10-09-2014, 05:40 AM
  2. Replies: 0
    Last Post: 02-17-2012, 07:12 PM
  3. Error 1004 Unable to set the Hidden Property of the Range Class
    By nld in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 08-08-2007, 10:56 AM
  4. 1004 - Unable to set the hidden property of the range class
    By Tim Whitley in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 02-20-2006, 05:55 PM
  5. 1004 Application-defined or object-defined error using Border(X).linestyle
    By leeds55 in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 02-19-2005, 12:14 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1