* Part-time 4WD: This system likely has a switch or dial with positions like 2WD, 4HI (4-wheel high), and 4LO (4-wheel low). Engaging 4HI is the closest thing to a "4WD lock," but it should only be used on low-traction surfaces or off-road. Using 4HI on dry pavement can cause drivetrain damage. 4LO is for extremely low speeds and off-road situations.
* Full-time 4WD (if equipped): Some higher trims or optional packages might have offered a full-time 4WD system. Even then, there isn't a simple "lock." Instead, the system automatically distributes power to all four wheels, constantly adjusting based on conditions.
In short: There's no single "4WD lock." The operation depends on the specific 4WD system of your particular 2010 Ram 1500. Consult your owner's manual to understand the operation of your truck's 4WD system.