Ejemplo n.º 1
0
        public static RegistryCaptureKey RegisterPackages(string fullPath)
        {
            // Capture the registration.

            RegistryCaptureKey captureKey;

            using (RegistryCapture registryCapture = new RegistryCapture(Constants.Wix.RegistryCaptureName))
            {
                VsUtil.RegisterPackages(fullPath);
                captureKey = registryCapture.Capture();
            }

            return(captureKey);
        }
Ejemplo n.º 2
0
        public static RegistryCaptureKey RegisterAssembly(string fullPath)
        {
            // Capture the registration.

            RegistryCaptureKey captureKey;

            using (RegistryCapture registryCapture = new RegistryCapture(Constants.Wix.RegistryCaptureName))
            {
                Assembly assembly = Assembly.LoadFile(fullPath);
                ComUtil.RegisterForInterop(assembly);
                captureKey = registryCapture.Capture();
            }

            // The assembly may have been loaded from the GAC which will be reflected in paths etc.  Need to fix them up.

            string fileName = Path.GetFileName(fullPath);

            ResolvePaths(captureKey, fileName, fullPath);

            return(captureKey);
        }