+ Reply to Thread
Results 1 to 5 of 5

vba if cell selected then change that column header to orientation 0

  1. #1
    Registered User
    Join Date
    10-22-2014
    Location
    Birmingham UK
    MS-Off Ver
    Various
    Posts
    55

    vba if cell selected then change that column header to orientation 0

    Hi

    I have this running at the moment but not doing exactly what i want

    I have dates stored in D4:CP4) with data below
    The dates atre formatted to orientation = -90
    what the below should be doing but isn't is
    all column widths to 4
    change all rows to -90
    then
    change the active column to 33
    change Columns A-C to their custom Widths
    then change the active column to Orientation 0
    It is however if i select the date cell it is turning it back to orientation 0
    any ideas?

    Please Login or Register  to view this content.

  2. #2
    Valued Forum Contributor xlbiznes's Avatar
    Join Date
    02-22-2013
    Location
    Bahrain
    MS-Off Ver
    Excel 2007
    Posts
    1,223

    Re: vba if cell selected then change that column header to orientation 0

    Put this line :
    Please Login or Register  to view this content.
    before
    Please Login or Register  to view this content.
    Happy Computing ,

    Xlbiznes.

    To show your appreciation please click *

  3. #3
    Registered User
    Join Date
    10-22-2014
    Location
    Birmingham UK
    MS-Off Ver
    Various
    Posts
    55

    Re: vba if cell selected then change that column header to orientation 0

    I have tried that but still no joy
    If a user was to select G8 for example then G4 would change to Orientation 0


    I have attached a sample workbook

    Thanks
    Attached Files Attached Files

  4. #4
    Valued Forum Contributor xlbiznes's Avatar
    Join Date
    02-22-2013
    Location
    Bahrain
    MS-Off Ver
    Excel 2007
    Posts
    1,223

    Re: vba if cell selected then change that column header to orientation 0

    Please try this :

    Please Login or Register  to view this content.

  5. #5
    Registered User
    Join Date
    10-22-2014
    Location
    Birmingham UK
    MS-Off Ver
    Various
    Posts
    55

    Re: vba if cell selected then change that column header to orientation 0

    Hi

    Thanks for your help

    I have added one extra line to get it to work and i have attached the workbook incase anyone else wants this

    Please Login or Register  to view this content.
    Rob
    Attached Files Attached Files

+ 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. Header and Footer in a different orientation
    By joleenc in forum Excel General
    Replies: 2
    Last Post: 09-25-2013, 06:49 PM
  2. Header/Footer changes when page orientation is changed
    By raperm in forum Word Formatting & General
    Replies: 2
    Last Post: 08-15-2013, 03:01 PM
  3. Change Orientation of One Cell Within Header
    By MSmithson in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 10-12-2010, 04:33 PM
  4. Getting Cell References to Change Orientation
    By nkissam in forum Excel General
    Replies: 12
    Last Post: 05-18-2007, 03:54 PM
  5. [SOLVED] Template for printing-orientation, header-footer setup
    By John Sullivan in forum Excel Formulas & Functions
    Replies: 0
    Last Post: 09-06-2005, 10:05 AM

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