This should work shouldnt it?
Code:
XpVehicleVersionCollection versionColl = new XpVehicleVersionCollection();
versionColl.Query.Where(versionColl.Query.BrandCode == "ALFA");
versionColl.Query.Load();
XpVehicleVersion first = versionColl[0];
XpVehicleVersion second = versionColl[1];
//get a car from the first VehicleColl
XpVehicle car = first.XpVehicleCollectionByXpVehicleVersionID[0];
//detach it
first.XpVehicleCollectionByXpVehicleVersionID.DetachEntity(car);
//and attach it to the second.
second.XpVehicleCollectionByXpVehicleVersionID.AttachEntity(car);
versionColl.Save();
I can see the VehicleVersionID change to the one I attach to in 'car'.
But when i do the versionColl.Save() the id get changed back to its originail.