Md. Abdul Kader

About author

MD. ABDUL KADER is an engineer with a talent for Excel and a passion for VBA programming. To him, programming is like a time-saving wizard, making data manipulation, file handling, and internet interactions a breeze. His skill set extends to SWM, GIS, RS, and SPSS. He holds a B.Sc in Urban & Regional Planning from Chittagong University of Engineering and Technology and has shifted to become a content developer. In this role, he crafts technical content centred around Excel and VBA. Outside the professional realm, catch him immersed in books, exploring new places during travels, and watching movies.

Designation

Team Leader at ExcelDemy in SOFTEKO.

Lives in

Dhaka, Bangladesh.

Education

B.Sc in Urban & Regional Planning, Chittagong University of Engineering and Technology

Expertise

SWM, GIS, RS, SPSS, MS Excel, PowerQuery, PowerPivot & VBA

Experience

  • Technical Content Writing
  • Team Management

Summary

  • Currently working as Team Leader of ExcelDemy.
  • He started writing technical content for Excel & VBA for ExcelDemy in 2021.

Latest Posts From Md. Abdul Kader

1
How to Drag a Formula Horizontally with Vertical Reference in Excel

We have a dataset, Sales Report of Fruit, which shows Product ID, Sales Rep, Fruits, States, and Sales. We will show you how to drag the formula horizontally ...

0
How to Maintain Store Inventory in Excel (Step by Step Guide)

Here's the overview of a store inventory management sheet we'll make. How to Maintain Store Inventory in Excel: 3 Steps We have some Fruit Items ...

1
[Fixed] Report Connections Slicer Not Showing All Pivot Tables

Report Connections is a feature to manage Pivot Tables that are connected with the Slicer tool. This feature will work if you add Slicer to a Pivot Table or ...

1
How to Interpret Multiple Regression Results in Excel

What Is Multiple Regression? When the number of independent variables is two or more while doing linear regression, it is called multiple linear regression ...

1
How to Share Excel File for Multiple Users

For working together in a team or organization, you might often need to share an Excel file. So that all of you can edit the workbook at the same time. In this ...

1
What to Do When Excel Is Not Responding? (11 Handy Tricks)

Method 1 – Opening an Excel Program in Safe Mode Steps: Go to the Windows search box and type ‘Run’; Click on the 'Run' app. Alternatively, press the ...

1
[Fixed:] Unsaved Excel File Not in Recovery

Let’s assume a situation when you’re working in Excel and it is closed unexpectedly. Then, you obviously rely on the Document Recovery pane of Excel that ...

2
How to Forecast Revenue in Excel (6 Methods)

Revenue simply refers to the earnings of an organization or company. For instance, consider the revenue (in cells E5:E14) of a company from 2014 to 2021. In ...

1
Excel Pivot Table: Difference between Two Columns (3 Cases)

Consider the dataset which contains the Sales Report for 2021 and 2022 of some Product Categories, along with Order Date and corresponding States. ...

0
How to Create a Database with a Form in Excel

What Is a Data Entry Form in Excel? An Excel Data Form is a handy tool that simplifies data entry by allowing you to input one complete record at a time, ...

1
How to Convert Word Table to Excel Spreadsheet: 6 Quick Methods

Assume that you have a table like the following one in your Word document. Here, the Sales Report of Fruit Items is given along with the necessary information ...

1
How to Read CSV File in Excel (5 Quick Tricks)

In this article, we'll walk through 5 easy methods for reading CSV files in Excel, and provide some tips for working with them. CSV, the ...

0
Print to PDF and Email Using VBA in Excel: 2 Useful Cases

Method 1 - Print to PDF and Email for Single Worksheet ➜ Open a module by clicking Developer > Visual Basic (or press ALT + F11). ➜ Go to Insert ...

0
How to Convert Notepad to Excel with Columns (5 Methods)

Sometimes your dataset might be stored in text (.txt) format. In Windows, text files are usually accessed using Notepad, a dedicated text editor application ...

0
How to Make Subtotal and Grand Total in Excel (4 Methods)

Consider the dataset as shown in the following screenshot. Here, the sales report contains Product Items, States, Price, Quantity, and Sales. We'll calculate ...

Browsing All Comments By: Md. Abdul Kader
  1. Hello EAC,
    Thanks for your question. Most likely, you need to put a not equal sign (<>) inside the If…Then statement of your second code. So, the corrected second code will be as follows-

    Sub block()
    Dim hz As String
    Dim hz1 As String
    
    hz = InputBox("enter your password")
    hz1 = InputBox("repeat password")
    
    If hz <> hz1 Then
    MsgBox "The repeated password is not identical!", vbExclamation
    hz = ""
    hz1 = ""
    Else
    Columns("D:F").Select
    Selection.Locked = False
    Range("D8:F12").Select
    Selection.Locked = True
    Range("a1").Select
    ActiveSheet.Protect hz
    End If
    End Sub

    However, your used three codes are quite messy. I would like to suggest that you can use the following code to lock a specific cell range in all worksheets of your Excel file.

    Sub Lock_CellRange_AllSheets()
        Dim ws As Worksheet
        For Each ws In ActiveWorkbook.Worksheets
            ws.Unprotect Password:="1234" 'Replace the password if you want
            ws.Range("D8:F12").Locked = True 'Replace the cell range
            ws.Protect Password:="1234", UserInterfaceOnly:=True 'Replace the password with the actual password for the workbook if it is protected
        Next ws
    End Sub

    Again, try this code to unlock the specific cell range in all worksheets.

    Sub Unlock_CellRange_AllSheets()
        Dim ws As Worksheet
        For Each ws In ActiveWorkbook.Worksheets
            ws.Unprotect Password:="1234" 'Replace the password if you want
            ws.Range("D8:F12").Locked = False 'Replace the cell range
            ws.Protect Password:="1234", UserInterfaceOnly:=True 'Replace the password with the actual password for the workbook if it is protected
        Next ws
    End Sub

    I hope these will work! Moreover, you can follow lock and unlock cells using VBA to explore more efficient methods.

  2. Hello Michael,
    Please specify your problem in detail or send the excel file via [email protected] email address.

  3. Dear Deka,
    It’s nice to hear from you with such wonderful appreciation. I myself always try to represent Excel applications in a more user-friendly way. And we, the ExcelDemy team, are working as a one-stop Excel solution provider.
    Thanks, and take care of yourself. Goodbye!
    Md. Abdul Kader
    Editor, ExcelDemy.

Advanced Excel Exercises with Solutions PDF

 

 

ExcelDemy
Logo