Click here to Skip to main content
15,897,334 members
Home / Discussions / C#
   

C#

 
GeneralRe: IntPtr to a structure Pin
Nnamdi Onyeyiri6-Jan-03 7:58
Nnamdi Onyeyiri6-Jan-03 7:58 
GeneralRe: IntPtr to a structure Pin
leppie6-Jan-03 8:04
leppie6-Jan-03 8:04 
GeneralRe: IntPtr to a structure Pin
James T. Johnson6-Jan-03 14:49
James T. Johnson6-Jan-03 14:49 
GeneralRe: IntPtr to a structure Pin
leppie6-Jan-03 19:43
leppie6-Jan-03 19:43 
GeneralRe: IntPtr to a structure Pin
Heath Stewart7-Jan-03 3:40
protectorHeath Stewart7-Jan-03 3:40 
GeneralRe: IntPtr to a structure Pin
leppie7-Jan-03 6:09
leppie7-Jan-03 6:09 
GeneralRe: IntPtr to a structure Pin
Heath Stewart7-Jan-03 7:56
protectorHeath Stewart7-Jan-03 7:56 
GeneralError in uninstalling the Windows Service Pin
jayakarthikeyan6-Jan-03 3:14
jayakarthikeyan6-Jan-03 3:14 
I got the following error while executing the installutil/u MyFile.exe. Refer the steps below:
---------------------------------------------------------------------------------------------------------------------------
Affected parameters are:
assemblypath = d:\test\filewatcher.exe
logfile = d:\test\filewatcher.InstallLog
An exception occurred during the uninstallation of the FileWatcher.SetupInstaller installer.
System.NullReferenceException: Object reference not set to an instance of an object.
An exception occurred while uninstalling. This exception will be ignored and the uninstall will continue. However, the application might not be

fully uninstalled after the uninstall is complete.
Removing EventLog source OFACFolderWatchService.
Service OFACFolderWatchService is being removed from the system...
Service OFACFolderWatchService was successfully removed from the system.
----------------------------------------------------------------------------------------------------------------------------------

Detailed Steps:
=========
I developed FileWatcher windows service using C# and created Microsoft Installer. Installation and Uninstallation was working fine.

Later I customized the Microsoft Installer by adding one Installer class (SetupInstaller.cs) to my existing FileWatcher project.

Added the Override method of base Class as:

public override void Install(System.Collections.IDictionary PassData)
{
//update the XML File
string strAppPath = System.Reflection.Assembly.GetExecutingAssembly().Location;
strAppPath = strAppPath.Substring(0,strAppPath.LastIndexOf("\\")+1);
string strXMLFile = strAppPath + "OFACTracker.xml";
XmlDocument objXMLDocument = new XmlDocument();
string strNodeValue = "";
try
{
objXMLDocument.Load(strXMLFile);

XmlNodeList objNodeList = objXMLDocument.GetElementsByTagName("InBox");
strNodeValue = strAppPath + "Inbox";
objNodeList.Item(0).FirstChild.Value = strNodeValue;


objXMLDocument.Save(strXMLFile);
}
catch(Exception)
{
//Exception Handling
}
}


Note:
ProjectInstaller.cs already exist while creating the service. I didnt touch this installer class.


Created Setup Package. Here I added Project group to an Application Folder of System Editor and Added custom Action to an Install Node.
In this case Installation was working file (Service registered automatically). Before Unstallation, executed Installutil/u FileWatcher.exe and got the above

error.

Thanks in Advance
Karthik

GeneralRe: Error in uninstalling the Windows Service Pin
Stephane Rodriguez.6-Jan-03 3:35
Stephane Rodriguez.6-Jan-03 3:35 
GeneralRe: Error in uninstalling the Windows Service Pin
jayakarthikeyan6-Jan-03 18:15
jayakarthikeyan6-Jan-03 18:15 
GeneralS.Rod :) Pin
Sijin5-Jan-03 23:55
Sijin5-Jan-03 23:55 
GeneralRe: S.Rod :) Pin
fretre6-Jan-03 1:56
fretre6-Jan-03 1:56 
QuestionHow to insert pictures to RichTextBox? Pin
wei_xiang5-Jan-03 20:56
wei_xiang5-Jan-03 20:56 
AnswerRe: How to insert pictures to RichTextBox? Pin
Stephane Rodriguez.6-Jan-03 3:47
Stephane Rodriguez.6-Jan-03 3:47 
GeneralRe: How to insert pictures to RichTextBox? Pin
wei_xiang6-Jan-03 14:44
wei_xiang6-Jan-03 14:44 
QuestionRunning an external proocess, How? Pin
fesenjoon5-Jan-03 20:48
fesenjoon5-Jan-03 20:48 
AnswerRe: Running an external proocess, How? Pin
Stephane Rodriguez.5-Jan-03 20:51
Stephane Rodriguez.5-Jan-03 20:51 
AnswerRe: Running an external proocess, How? Pin
wei_xiang6-Jan-03 14:35
wei_xiang6-Jan-03 14:35 
GeneralRe: Running an external proocess, How? Pin
Stephane Rodriguez.6-Jan-03 19:08
Stephane Rodriguez.6-Jan-03 19:08 
GeneralNew ECMA submission for VC# 1.1 Pin
SimonS5-Jan-03 20:06
SimonS5-Jan-03 20:06 
GeneralRe: New ECMA submission for VC# 1.1 Pin
Stephane Rodriguez.5-Jan-03 20:52
Stephane Rodriguez.5-Jan-03 20:52 
GeneralRe: New ECMA submission for VC# 1.1 Pin
Eric Gunnerson (msft)6-Jan-03 13:25
Eric Gunnerson (msft)6-Jan-03 13:25 
GeneralCustom sorting in TreeView Pin
Wizard_015-Jan-03 5:18
Wizard_015-Jan-03 5:18 
GeneralRe: Custom sorting in TreeView Pin
Stephane Rodriguez.5-Jan-03 5:41
Stephane Rodriguez.5-Jan-03 5:41 
Questionhow to get other key event? Pin
fretre5-Jan-03 5:04
fretre5-Jan-03 5:04 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.