How many miles are on the Bike ,Which year, and model of Buell?Welcome to the forum also.
There were Several yers of Xbs that had some ISSUES with the Regulator Connector!
It wpuld get burned up connector wires inside the Plugs Assembly. There is an upgrade fix kit for that to stop it from happening(that problem)again. You can get that IF needed from the Dealer OR American Sportbike .com.
If you have a BUELL Friendly Dealer rhen the price on that part is pretty close in Cost.Harley Davidson has kinda left us Black Sheep UHHH-Buellers out to Pasture some Dealers Counter Sales are actually helpful so good luck in that Department.
Remove the Battery and Load Test it out of the Bike.
Some Auto Stores will do it for free.
Once you know the Battery is in good shape and reinstalled. Try to restart, NOW if it does the Same as before, stop and take the Fuse out that controls the Headlights.
If still does the Same thing DO NOT try and jump it with any booster . The Starter Maybe possible be in a stuck position from Low Voltage Start(from before)when it first happened.
The Relay needs to be marked that goes to the Starter. MARK it so when you change another Relay from its' area and put it in where you just removed the Possible Bad Relay. Either a combination of things are happening. SAY the Starter is Stuck then you will need to unjam it by Taping on the Solenoid with a small SAY a ball peen hammer OR a small piece of wood handle against the starters solenoid and TAPPED with the Hammer is a better way.
Don't kill it banging to hard on the Starter. IF That works then you need a Starter.
Check all the Grounds and connections if you were having a problem with [Voltage] then test the Charging system starting from the Battery that is NOW known to be a good one. If the Battery [will] Start the Engine then test Voltage at the Battery. Your Volts at Idling will(Should be) 12.6 volts. If you do get it started and the [Voltage Reading] is TOO much OR too high AT Idle(12.6) that means the Regulator needs to be Replaced. Also you need to be prepared to replace the [Stator] it will go out soon as well.
Of course I made a Liar out of myself when my Regulator 08/XB12R went out the Stator took about 2'900.miles to go out after I had replaced it(Regulator)that is. So post up and let us know how and what you find. There is a Detailed Diagnous of the Electrical step by step that is on the Forum. Look Up stevenc150 where he and so many of us have put some good ways to check the Bikes so you can get it riding soon. Check out the Mods Section as soon as you get time. IF you can't find it, post up and someone will get that for you.Good Luck.*Jimi