The Reginald Barclay hologram was created by the real Reginald Barclay in 2377 in order to be transmitted to USS Voyager in the Delta Quadrant through the datastream.
Two attempts to send it failed because it was intercepted by the Ferengi Nunk. He had the hologram altered in order to carry out a plan to trick Voyager to come to him in the Alpha Quadrant by entering a geodesic fold, which would kill all of Voyager's crew. Nunk was after Seven of Nine's nanoprobes, which would be worth billions of times their own weight in latinum. The altered hologram was then sent on to Voyager where they remained unaware of the modifications.
The Barclay hologram nearly succeeded until the real Barclay at Starfleet Headquarters discovered the plan. The real Barclay impersonated his hologram in a communication and tricked Nunk into closing the geodesic fold before Voyager could enter it. The Barclay hologram left Voyager with Seven, who he had incapacitated, in an escape pod and attempted to enter the closing fold, but Harry Kim beamed them out before they could reach it.
The Voyager crew deactivated him.
The real Barclay later upgraded the hologram's security to make sure it could not be compromised in the future.