Show SQL server script error in WIX setup -


i've setup project in vs2013 using wix. setup executes sql scripts on sql server. i'd find way add raiserror messages (with severity <11) installation log , show them user.

  1. your sql script should executed using custom action.
  2. use system.data.sqlclient.sqlcommand execute script.
  3. then surround try catch , catch exception , show error message below.

    try {

    // code execute script. 

    }

    catch (exception e)

    {
    session.message(installmessage.warning, new record(new string[] { e.message }));

    }


Comments

Popular posts from this blog

php - failed to open stream: HTTP request failed! HTTP/1.0 400 Bad Request -

java - How to filter a backspace keyboard input -

java - Show Soft Keyboard when EditText Appears -