Consulting

Results 1 to 2 of 2

Thread: How to apply VBA formula to stop row height from readjusting ? (Excel File)

  1. #1
    VBAX Newbie
    Joined
    May 2021
    Posts
    1
    Location

    How to apply VBA formula to stop row height from readjusting ? (Excel File)

    Hi all,

    I am a beginner in VBA.

    I am currently working on a excel file where it is created like a form (but I am not using the Form Creation function).

    However, as I extend the excel file to another user, the forms appearance will be truncated as the row height will be readjusted, if the file is opened from other Devices (other Laptop/Desktop).

    I have locked the workbook, but the other recipient who opened the excel file will noticed the difference between the original excel file and the excel file that they received.

    Anyone have encountered this issue before? Not sure whether applying VBA formula in the excel will help to lock the row height from readjusting. However, I am not sure how can it be done, Hope to get some enlightenment from the community. Thanks

  2. #2
    VBAX Mentor
    Joined
    Nov 2020
    Location
    Cochin, Kerala
    Posts
    314
    Location
    You can set back your desired row height in the worksheet change event

    For example

    Private Sub Worksheet_SelectionChange(ByVal Target As Range)
    Target.RowHeight = 15
    End Sub
    OR

    Range("A1:A10").RowHeight = 15

Tags for this Thread

Posting Permissions

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