>>Noooo!:-) It's a bad idea. The reason I say this is: If it isn't read-only and you subtract 1, you'll modify the other bits too. Same thing with adding. Further, with the folder object at least, the directory bit is read-only and will error on you. Use the bitwise operators always.
>
>I see. I suppose you need to check the setting first if you want to go this way.
>
>Thanks.
No need to check, AFAIK. BITOR() will set a certain byte, BITAND() will reset it, BITXOR() will toggle it.
Hilmar.
Difference in opinions hath cost many millions of lives: for instance, whether flesh be bread, or bread be flesh; whether whistling be a vice or a virtue; whether it be better to kiss a post, or throw it into the fire... (from Gulliver's Travels)