Preheat oven to 425°F.
Prepare your pan by lining it with enough overhang to crimp to another piece large enough to cover. Set aside.
Prepare your butter: Stir together butter, garlic powder, parsley, chives, rosemary, thyme, salt, and pepper in a bowl until combined. Taste and adjust seasoning.
Using a little of the herbed butter and clean hands, generously coat each cob and place in the pan. After all are added, crimp the top piece of foil over the pan and seal well.
Place in hot oven and roast for 20 minutes for crisp-tender, a little longer for softer corn. Remove and brush with more herbed butter.
Find it online: https://frugalhausfrau.com/2021/08/29/oven-roasted-sweet-corn/