I’m not sure what you mean by both signals. Are you referring to a flat pair, two signals facing opposite directions on a single track as in the diagram below? Signals A faces east and govern westbound movement with B facing west governing eastbound trains.
........................................................... Signal A >
West ========== Block 1 ==========|=X======== Block 2 ========== East
........................................................ < Signal B
If that’s what you mean and I understand you correctly, when there’s an eastbound train in Block 1 you want the pair lit and when it leaves Block 1 you want them both to go dark. I don’t think there’s a way to do this in Trainz. Prototype railroads employed two or more detection circuits in each block so that they could detect not only block occupancy, but the direction that the train was moving as well. This would allow them to light Signal A if a train was approaching from the west (though I’m unclear why they would want to do this if Block 2 was unoccupied) and to leave A dark if the train in Block 2 was traveling east. For signaling purposes, Trainz seems to only detect if a block is occupied and ignore the direction the train is moving.
If they’re permissive (have a number plate), you can configure the Safetran signals to be Approach Lit (by default they are not). This will do half of what you want by making B go dark when the train enters Block 2, but A will stay lit as long as the train is in the block. You might be able to place an invisible signal directly in advance of Signal A (the X in the diagram) to cause A to go dark almost immediately after the train passes, but it would overlap Signal A and I’m not sure what problems that might cause. Having them so close together could also mess up westbound trains when A was red. I can’t think of a way to cause A to be lit with Block 2 is unoccupied, but I often miss the obvious and maybe someone else can.
I hope I understood your question correctly and this helped, even though it wasn’t the answer you wanted.