Why did the first Boeing B17 test flight crash on takeoff?
The prototype aircraft had small "blocks" (more like wedges) which were used to prevent the control surfaces moving in the wind and potentially damaging the control surfaces, or even moving the aircraft on the ground. A bit like putting chocks under the wheels to stop the aircraft rolling.

These were not removed when the aircraft was taken on a test flight, so the control surfaces could not move. Essentially, they were "fixed" in an approximately neutral position. Imagine if you couldn't move your steering wheel in your car because someone had put wedges next to your front wheels to prevent them turning: that's basically the situation the pilots were dealing with, but unlike you they can't just hit the brakes and stop once the aircraft is in the air.

The Boeing 299 / B-17 are "taildragger" aircraft.

As you can see in this photograph which I won't link directly due to the size, the aircraft's nose is pointing quite sharply "up" when on the ground.

Here's a B-17, which isn't identical to the Type 299 but is close enough that it makes no difference. Hopefully this gives you the visual to see why the aircraft will lift off at a high enough speed.



When accelerating the nose being pointed slightly up gives a positive angle of attack for the wings. This means that once the aircraft gets above stall speed, it will naturally lift off into the air. Essentially, the aircraft is already pitched slightly up before any control surfaces are moved.

That also means that when the aircraft takes off, it will climb - at least initially. With the locked elevators, there is no way to change the pitch angle of the aircraft, and the aircraft will either pitch up or down naturally - there is almost no chance that the aircraft would be perfectly trimmed by accident.

In this case, the position the elevators were locked caused the aircraft to continue pitching up until it stalled. The crew had no way to correct this and the aircraft stalled out, rolled and crashed into the ground.