How can you get representation by a public defender before going to court. It seems you have to go to court and plead not guilty in order to be assigned to a public defender. The thing is I am guilty of what I am being accused of petty theft. How can I work this out without lying to the judge and still get representation? My court date is this Friday, so if anyone can give me advice as I am running out of time. I would greatly appreciate it.