Hrm... if you're not sending the header, now that I think about it, you won't have the stylesheet set and may not be able to use the $tbopen/$tbclose setup. You might be able to manually set a stylesheet in your header then try using the function that grabs the tablewrappers and see if that works.