Answer: When we locate a particular section of DNA, we know about the specific nucleotide sequence that it has. From the nucleotide sequence, we can know the respective protein sequence that it would encode for.
So, we will allow the section of DNA to get transcribed ( formation of mRNA from DNA) so that it forms mRNA ( messenger RNA), which is then translated to form a particular protein.
Therefore, we can see what protein is formed by that DNA by allowing it to transcribe and then translate.
By doing so, we could be sure that we have located a section of DNA that encodes for protein.