I was at my wit's end.
Tohō ni kureru.
way; destination; reason
at (place, time); in; on; during; to (direction, state); toward; into; for (purpose); because of (reason); for; with; by; from; as (i.e. in the role of); per; in; for; a (e.g. "once a month"); and; in addition to; if; although
to get dark; to end; to come to an end; to close; to run out; to be sunk (e.g. in despair); to be lost