Where did you get the battery you installed and how long ago was that?
If the computer runs when connected to the external power supply, it's almost certain that that power supply is OK (there's a very small possibility that it is supplying enough power to run the computer but not enough to charge the battery).
That leaves two possibilities: the battery has failed or the charging circuitry inside the laptop has failed. The first possibility is by far the most likely. Laptop batteries do fail, especially if the current battery is an "off-brand" replacement.
Your Toshiba should have PC Health Monitor software that you should use to check your battery's health before buying a new one. See the directions here: https://smallbusiness.chron.com/check-status-battery-toshiba-laptop-54548.html
If you don't have that Toshiba software, do this:
- Click Start, type Command Prompt in the Search box, right-click on the link to Command Prompt, and select "Run as administrator." Respond as necessary to the UAC prompt.
- Type the following in the black Command Prompt window and press Enter
powercfg -energy - Wait 60 seconds (or a bit longer) until the command completes, the open Windows Explorer (the file manager) and navigate to C:\Windows\System32\energy-report.html and double-click that file.
- The report will open in your web browser. Scroll down to the "Battery Information" section.
From the help file for powercfg:
Analyze the system for common energy-efficiency and battery lifeproblems. The ENERGY command should be used when the computer isidle and with no open programs or documents. The ENERGY commandwill generate an HTML report file in the current path.
Here's a typical output: