View Single Post
  #22  
Unread 11-28-2007, 05:41 PM
Ripper-Joe Ripper-Joe is offline
A Forest Scavenger
 
Join Date: May 2006
Server: Antonia Bayle
Posts: 15
Default

Okay, prepare to go nuts (I know I'm going nuts now!).

I did a clean install of Test4 and here's what happen. The installer created a much more complete Config file (however the config file does not match the previous test config file in the order in which the variables are defined). Upon firing up the updater after the install, I receive the now familiar:

Code:
Unknown Error: EQ2MAP_Updater
   at EQ2MAPUpdater.GlobalVariables.ReadConfigValues()
   at EQ2MAPUpdater.MainWindow.FormMain_Load(Object sender, EventArgs e)
   at System.Windows.Forms.Form.OnLoad(EventArgs e)
   at System.Windows.Forms.Form.OnCreateControl()
   at System.Windows.Forms.Control.CreateControl(Boolean fIgnoreVisible)
   at System.Windows.Forms.Control.CreateControl()
   at System.Windows.Forms.Control.WmShowWindow(Message& m)
   at System.Windows.Forms.Control.WndProc(Message& m)
   at System.Windows.Forms.ScrollableControl.WndProc(Message& m)
   at System.Windows.Forms.ContainerControl.WndProc(Message& m)
   at System.Windows.Forms.Form.WmShowWindow(Message& m)
   at System.Windows.Forms.Form.WndProc(Message& m)
   at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
   at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
   at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)Object reference not set to an instance of an object.
So on a whim, I renamed the config file created by Test4 installer to eq2MAP_config.cfg.bak (just to move it out of the way without altering its contents) and I copied in the example config file you provided me previously just to see if the differences between the two config files made a difference.

Using the Test4 installed files but with the older config file, the program works normally. However when config file Test4's installer created is in use, the program fails.

So I took a look at the two config files and compared them. I see the "full" config file created by Test4's installer does not define some variables that are defined in the working config file. I then set about adding the missing variables one at a time to see which ones the Updater seems to feel are required.

Lucky for me, I hit gold on the first try. It appears the OptionName "EQ2Dir" can not be left to a null value. It must be defined. Below shows which line I changed and what I changed it to.

From:
<OptionName>EQ2Dir</OptionName>
<OptionValue></OptionValue>
To:
<OptionName>EQ2Dir</OptionName>
<OptionValue>C:\games\Sony\EverQuest II</OptionValue>

After adding the EQ2 path the updater fired up properly and worked normally. All other values were left exactly as the Test4 installer created them.

Knowing full well that I have installed EQ2 to a non standard installation directory (c:\games rather than c:\program files) I decided to see how the updater would react if I put in the default path into the config file even though it would not be able to find my installation at that path. Much to my amusement, the updater did NOT produce an error when the path was set to a different location than my EQ2 installation but it DOES produce an error if the path is not defined at all!

For extra credit, I decided to take this one step further and create a config file that ONLY contained the EQ2DIR variable. (I can't leave well enough alone.) This produced a very interesting result. With a config file containing ONLY the following...

Code:
<?xml version="1.0" standalone="yes"?>
<ConfigOpt>
  <ConfigValues>
    <OptionName>EQ2Dir</OptionName>
    <OptionValue>C:\Games\Sony\EverQuest II</OptionValue>
  </ConfigValues>
</ConfigOpt>
The updater launches WITHOUT AN ERROR!!! Furthermore, the updater assumes several default options and actually populates the rest of the variables into the config file after the first launch!

My only complaint at all with the minimized modified config file and the default assumptions of the updater is that it defaults to Autoupdate True and Autolaunch True. As a result, if you happen to have the wrong EQ2DIR path defined in the minimized config file, the updater will start patching the wrong folder and will fail to launch the EQ2 application before you have time to click Options and set the path correctly.

So, in summary, it appears the updater requires the EQ2DIR variable to be set in the config file. A null value in this line of the config will produce an error at start up but when the path is defined (even if it is wrong) the updater will launch normally even in the absence of any other lines in the config file.

It seems if you can either provide a prompt durring the installation to ask the user what their EQ2 installation directory is (and write that value directly to a minimized config file upon installation) or if you can change the way in which the updater reacts to the absence of the EQ2DIR variable, you may have licked this issue! I would suggest you change the defaults for Autoupdate and Autolaunch though just in case..
Reply With Quote