P18F4550,
One of the pitfalls of the C/C++ programming language is that it will let you have an expression that does nothing. Your statements don't change the port. Here's one way to do it:
void loop()
{
PB7 = PB7 | on;
delay(500);
PB7 = PB7 & ~on;
delay(500);
}
Also, note that the AND operator is used to clear bits, not the OR operator.
Regards,
-Mike