How do I search by only the project/activity ID?

General Questions
You can get directly to project or activity details page by entering its ID to the Find Bar in the header menu while you are in the Activity Center or Project Calendar page (or older Activities classic and Projects pages):

 
Or in the Activity Center you can type an ID to the quick find/filter "Filter by" field so the filter will be created to show a project or activity you are looking for: