Harry Adams, 22, and Nathan Smedley, 26, burst through an unlocked door at the property in Parkgate, Rotherham at around 8pm on June 3 this year, Sheffield Crown Court heard.
"According to witnesses, as they walked in Smedley shouted: 'What have you got for us then?' They were described as shouting and being aggressive. Smedley elbowed one of the occupants, causing her to fall to the floor. Smedley thought the person was a man and apologised to her when he realised she was a woman," prosecutor, Carl Fitch, said.
He added: "Both defendants went into the kitchen and came back carrying a knife and a large meat fork and made threats to the family."
Mr Fitch told the court that as the altercation was taking at the property, which he described as a 'doss house,' a number of people inside the house left via the back door and a member of the group called the police.
"Both defendants came out of the house and shouted: 'They better not be on the phone to the police'. However the police had already been called at that stage," said Mr Fitch, adding: "The female occupant came outside the house and Smedley got hold of her. She was wearing a long scarf, he got hold of it and pulled her towards the car. She got in the car and drove off at speed."
Smedley and Adams were arrested near to the scene a short time later, and Smedley was found to be in possession of small amounts of cannabis and cocaine which he claimed were for personal use, the court heard.
Both Smedley, of Church Avenue, Rawmarsh, Rotherham and Adams, of Ingshead Avenue, Rawmarsh, Rotherham were found to be under the influence of cocaine at the time of their arrest.
The defendants were initially charged with attempted robbery and weapon offences. However, these charges were dropped by the Crown Prosecution Service (CPS) when Smedley and Adams pleaded guilty to affray on the agreement, or basis of plea, that the CPS would not proceed with the other charges.
Judge Graham Reeds QC told the defendants that because the CPS had dropped the attempted robbery and weapons charges, and witnesses to the incident had refused to co-operate with the courts, he would have to sentence them based on the only evidence he had which was CCTV footage of what had happened outside the house.
He sentenced both men to a 12 month community order and ordered them to complete 180 hours of unpaid work. Smedley received no additional punishment for the charges of possession of cocaine and cannabis he pleaded guilty to at an earlier hearing.
"I have suspicion of why you went round to that property. But it's impossible to say what the intention was for this offence, or what your motivation was. The police were informed that something had happened, and you accept there was unlawful violence," Judge Reeds told the men.