About lunch time yesterday local police responded to reports of a man trespassing on a property at Kikori Place, Glenfield.
Officers went to the premises where they arrested a 29-year-old man.
He was taken to Macquarie Fields Police Station.
But as well as being charged with trespassing, the man was charged with attempted robbery armed with an offensive weapon.
This charge and one of intent to cause grievous bodily harm was related to an attempted robbery that took place in Glenfield on June 13.
A 76 year old man was stabbed during the attempted robbery of the convenience store.
Shortly after 10.20am on Monday, June 13, the elderly man entered a convenience store on Railway Parade after hearing raised voices.
Police allege a second man in the store, who was armed with a knife, was attempting to rob the store at the time.
The pair became involved in an altercation when the older man was allegedly assaulted and stabbed in the back.
The armed man fled the scene, empty handed.
The elderly injured man was treated at the scene by Ambulance Paramedics and was taken to hospital in a stable condition.
An employee who was also in the store at the time of the incident was not injured.
The 29 year old man arrested yesterday was refused bail.
He was scheduled to appear at Campbelltown Local Court today.