In your wxs, where do you define the following properties...
EXCEPTIONDETAILS
CURRENTDIRECTORY
DATABASE_VERSION

I also really wouldn't log to a Network Share in an exception handler.
When run with Administrative privileges network shares are disconnected..
If your catch throws an exception this will bubble up to the WiX engine which 
will trigger a rollback.

Do nothing in your catch and see if it works.. Or put a try catch inside your 
catch block and a message box. I think you'll find your exception handler is 
throwing an exception.


Regards,
Bevan

> Date: Tue, 18 Mar 2014 23:55:57 +0000
> From: Alan Smith <the_red_baro...@hotmail.com>
> Subject: [WiX-users] Custom Action error Handling in Wix 3.7 
> ...
>        catch (System.Data.SqlClient.SqlException ex)
>        {
>            session.Log("ERROR in custom action GetDBVersion {0}",
>            ex.ToString());
>            session["EXCEPTIONDETAILS"] = ex.ToString();
>            string dir = session["CURRENTDIRECTORY"];
>            string filepath = dir + "\\Logs\\CustomAction.log";
>            File.AppendAllText(filepath, "ERROR in custom action GetDBVersion 
> - " + ex.ToString() + "\n");
>            session["DATABASE_VERSION"] = "ERROR";
>        }
>        catch (Exception ex)
>        {
>            session.Log("ERROR in custom action GetDBVersion-Generic {0}",
>            ex.ToString());
>            session["EXCEPTIONDETAILS"] = ex.ToString();
>            string dir = session["CURRENTDIRECTORY"];
>            string filepath = dir + "\\Logs\\CustomAction.log";
>            File.AppendAllText(filepath, "ERROR in custom action 
> GetDBVersion-Generic - " + ex.ToString() + "\n");
>            session["DATABASE_VERSION"] = "ERROR";
>        }
>        return ActionResult.Success;
>    }

------------------------------------------------------------------------------
Learn Graph Databases - Download FREE O'Reilly Book
"Graph Databases" is the definitive new guide to graph databases and their
applications. Written by three acclaimed leaders in the field,
this first edition is now available. Download your free book today!
http://p.sf.net/sfu/13534_NeoTech
_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users

Reply via email to