'In remix, the output result of using Injected Web3 is "-"

In remix, using the Javascript VM environment to call the contract method to create a new contract can output a new contract address, but the output result of using Injected Web3 is "-"

How can I solve this problem?

enter image description hereenter image description here

I don't know how i can fix it.



Solution 1:[1]

Since your are using injected Web3 , im assuming your using metamask as your provider if so i believe you should check the transaction hash on the blockchain scan website rather than checking remix output since remix is trying to get the transaction result and could not parse the output.

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1