Auto-calculated field which includes letters and numbers
Don't do the SELECT MAX thing; you can run into concurrency problems there. If the patterns are simple enough, and have only a single increasing numeric portion, you can probably get away with using an identity column plus a persisted computed column to create the formatted string value:

CREATE TABLE IDTest (
    row_id int IDENTITY(1,1) NOT NULL,
    part_id AS 'M' + REPLICATE('0', 10 - LEN(CAST(row_id AS varchar(10)))) + CAST(row_id AS varchar(10)) PERSISTED,
    part_name varchar(50) NOT NULL
)

INSERT INTO IDTest (part_name) VALUES ('First part'), ('Second part'), ('Third part')

SELECT * FROM IDTest


If your patterns need to get fancier than that (multiple numeric segments, variations in the letters, etc.) then take a look at using sequences and triggers.