萬不得已

万不得已
wàn
only when absolutely essential (idiom); as a last resort

CEDICT

out of absolute necessity; with no other choice; as a last resort

Wiktionary

毫無辦法不得不如此

重編國語辭典

毫無辦法無可奈何不得不這樣

維基詞典

Entry Composition