When Jack Straw stands up in the Commons on Monday to announce the shelving of the referendum on the European Constitution - he will be doing so on an historic anniversary. For 6 June is thirty years to the day since votes were counted in the only referendum the British people have ever had on Europe.

The choice was whether or not we should stay in the Common Market, which we'd joined two years earlier. To start with, two-thirds of the public wanted us out, but by end the figures were exactly reversed.

So how did this remarkable transformation came about? It's a tragi-comic tale of high politics and low cunning that yoked together the strangest of bedfellows.

In March 1974, Harold Wilson had become Labour Prime Minister, pledged to holding a referendum. Pro-Europeans had wasted no time in preparing for the campaign, with the Dorchester Hotel in Mayfair as its top-secret headquarters.

"We had to have somewhere private to meet," says the millionaire businessman, Alastair McAlpine, later to become Tory Party treasurer. "My family owned the Dorchester and so I had some sway with the management."

Politicians from the left and right who were normally sworn political enemies, along with pro-market industrialists, would be discreetly summoned. "Somebody would telephone you and say could you come to breakfast on Tuesday at the Dorchester," remembers Lord Rodgers, then a Labour Minister. "You never quite knew who was going to turn up - it was mix of people from all parties who were united by a common idea," says Lord Hurd, a Tory MP working on the "yes" campaign.

"They were very good breakfasts," says McAlpine. "Kidneys, sausages, bacon, scrambled egg, kippers, all that kind of thing, laid out on a big buffet. The point of the buffet was we didn't have any waiters in the room - so no one could hear what we were plotting - and it was good plotting stuff."

"It was a world away from draughty Labour party committee rooms, soft biscuits and the milky brown concoctions that passed for tea," says Rodgers. "And it was this personal contact which made the difference and we built the 'yes' organisation."

In April 1975, Wilson called the referendum. His Cabinet was split down the middle on Europe with Tony Benn, the Industry Secretary, leading the anti-marketeers and Roy Jenkins, the Home Secretary, the pros. Wilson now made the unprecedented decision to suspend collective Cabinet responsibility and allow his ministers to campaign publicly against each other.

When I asked Jenkins at that time what effect he thought that decision would have on the unity of the Cabinet, he replied: "I do hope this whole wefewendum campaign can be conducted with out any wancour on either side." The sound recordist had to stifle a fit of giggles.

From the start, it was clear that there was nothing like a balance of power between the two sides. The "yes" campaign was well staffed, well funded and well organised and consisted of like-minded people from the centre ground of the three main parties.

The "no"s by came largely from the left wing of the Labour Party, the right wing of the Tories and the far fringes beyond - from the National Front to the Communist Party. And they had minimal resources.

When I filmed 30 years ago at the HQ of the "yes" campaign, I saw graphic evidence of the disparity in funding between the two campaigns. The sloaney figure of Caroline de Courcey Ireland told me how she was organising plane-loads of pro-European speakers from all parties across the country to be flown for briefings by top level Eurocrats.

"We chartered a series of 100-seater jet planes from British Caledonian airlines - and all those nice little girls in their kilts. We took nearly 1,000 in all"

And where, I asked her 30 years on, had the money come from? "From the European Commission: it was a sort of special dispensation. I don't know how they fixed it, because one didn't ask too much. One just said 'Thank you very much' and got on with organising it."

That fact was not known at time. But it was known that big business in Britain was overwhelmingly pro-European. "When the campaign started, money rolled in," says McAlpine, "yes" campaign treasurer. "The banks and the big industrial companies put in very large sums of money."

And what about the idea that you could be seen as fat cats who wanted to stay in Europe, I asked McAlpine.

"We were the fat cats. But we were the intelligent cats - the cats who knew about the economy. We were the cats who were warning the public that if they took us out of the Common Market they'd be out of work: the economy would collapse."

After its months of meticulous planning, the "yes" campaign emerged publicly at the Dorchester. Sharing the launch platform with Roy Jenkins were Willie Whitelaw, the Tory Deputy Leader, and the Jo Grimond, the former Liberal Leader.

"Of course we didn't know each other very well to start with," says Hurd. "And there was a slightly daring feel about working together with people who were normally your political enemies. It was rather like tip-toeing into a brothel - you felt that you were doing something which might or might not be pleasant but was certainly rather risque."

The "no" campaign eschewed such dangerous liaisons. And the fact that leading anti-Marketeers included such figures as Enoch Powell, Tony Benn and Dr Ian Paisley played into the hands of the pro-Europeans' strategy.

"What did those individuals do they have in common?," asks Hurd. "They were all in a literal sense eccentric - outside the centre of things."

McAlpine puts it less obliquely: "The whole thrust of our campaign was to depict the anti-marketeers as unreliable people - dangerous people who would lead you down the wrong path. It wasn't so much that it was sensible to stay in, but that anybody that proposed that we came out was off their rocker or virtually Marxist."

I put this point to Benn - saying that opinion polls at the time all gave a negative rating the leading "no" campaigners like himself and Powell - while the "yes" men all had a positive rating. "Media coverage," he responded. "If you haven't got a single newspaper supporting you, you don't expect good coverage. It's quite straightforward - nothing strange about it."

Tony Benn had a point. As the campaign got into its stride it became clear that, almost without exception, the press was pro-Europe - including Rupert Murdoch's Sun, The Daily Mail and The Daily Telegraph. Only the Communist Morning Star was anti-Market.

With the press stacked against them, the "no" campaign put a great premium on television. As in a general election the two sides had their own series of broadcasts. Again the disparity was obvious. The "yes" broadcasts used the new techniques of filming their star speakers on location with hand held cameras. They wanted to counter their elitist image.

"We would film people protesting directly to our speakers," says the director of the "yes" broadcasts, Justin Cartwright, later to become a celebrated novelist. "But of course we would trump them in the cutting room, by giving our speakers the final say."

The broadcasts, which went out simultaneously across the only three channels there were, would attract audiences of up to 20 million people. Shirley Williams, a pro-European Cabinet Minister, says: "The sheer liveliness and the tremendously close relationship - almost a physical touching - of the politicians to the people crowding round them is an image you never see anymore."

In contrast the "no"s were restricted to studio broadcasts presented by two political journalists - Paul Johnson and Patrick Cosgrave - reading sternly from an autocue. Johnson told me the "no"s excluded Benn, fearing he would alienate viewers.

As the opinion polls steadily turned against the "no"s, Benn decided to up the ante. He used his authority as Industry Minister to make a headline-grabbing claim: "Half a million jobs lost in Britain and a huge increase in food prices as a direct result of our entry into the Common Market"

These claims earned a magisterial rebuke from Roy Jenkins. "I'm afraid I find it increasingly difficult to take Mr Benn seriously as an Economic Minister. The technique is just to think of a number and double it, and if challenged you just react by thinking up some new claim."

The press gleefully took up Benn-baiting -with the Daily Mirror labelling him "The Minister of Fear" and other papers depicting him as "dangerous", "devious", "fanatical" and "lunatic".

Benn responds: "All the Party Leaders, all the money and all the newspapers proprietors were determined to get a "yes" vote and destroy anyone who took a contrary view. Full stop."

"No, that's not right," responds Shirley Williams. "Don't forget this was the point at which Tony was fairly extreme."

When the votes were counted thirty years ago - it was clear the well-oiled "yes" machine had succeed in dramatically transforming public opinion.

So how does Tony Benn see things now? "You have to make your case - and sometimes you win, sometimes you lose. But in the sense that Margaret. Thatcher has now come round to my view, Rupert Murdoch has now come round to my view, it wasn't unsuccessful, was it?"

Michael Cockerell's film 'How We Fell for Europe' is on BBC2 at 8.25 tonight.