EditXML update request...

Got a problem you cannot solve? Try here.
ckaware
Posts: 125
Joined: Thu Mar 17, 2011 11:43 am

EditXML update request...

Postby ckaware » Tue Sep 13, 2011 6:35 am

I'd like to request an EditXML update that allows the user to modify an existing XML file like the following without having to remove/ add the key...

<PRODUCTSettings>
<PRODUCTSetting Name="IP" Type="string" Value="127.0.0.1"/>
<PRODUCTSetting Name="Revision" Type="string" Value="$VERSION$"/>
<PRODUCTSetting Name="uploadDir" Type="string" Value="C:\Temp"/>
<PRODUCTSetting Name="PreProcessing" Type="boolean" Value="true"/>
<PRODUCTSetting Name="BaseDir" Type="string" Value="$TARGETDIR$\$VERSION$\Base"/>
<PRODUCTSetting Name="CommonDir" Type="string" Value="$TARGETDIR$\common"/>
</PRODUCTSettings>

What if InstallAware was able to take an XML file and with a simple check box option "resolve all InstallAware variables" within that file?

In the above example, TARGETDIR and VERSION are updated at install time.

Thoughts and thanks,

Chris

ckaware
Posts: 125
Joined: Thu Mar 17, 2011 11:43 am

Re: EditXML update request...

Postby ckaware » Tue Sep 13, 2011 8:56 am

Also,

When I use EditXML all of my comments within the XML are removed:

<!--
******************************************************************
* Comment
******************************************************************
-->

Is removed from the original file.

How can I avoid this?

Chris

giaviv
Posts: 2039
Joined: Fri Dec 17, 2010 1:39 pm

Re: EditXML update request...

Postby giaviv » Tue Sep 13, 2011 3:11 pm

ckaware wrote:I'd like to request an EditXML update that allows the user to modify an existing XML file like the following without having to remove/ add the key...

<PRODUCTSettings>
<PRODUCTSetting Name="IP" Type="string" Value="127.0.0.1"/>
<PRODUCTSetting Name="Revision" Type="string" Value="$VERSION$"/>
<PRODUCTSetting Name="uploadDir" Type="string" Value="C:\Temp"/>
<PRODUCTSetting Name="PreProcessing" Type="boolean" Value="true"/>
<PRODUCTSetting Name="BaseDir" Type="string" Value="$TARGETDIR$\$VERSION$\Base"/>
<PRODUCTSetting Name="CommonDir" Type="string" Value="$TARGETDIR$\common"/>
</PRODUCTSettings>

What if InstallAware was able to take an XML file and with a simple check box option "resolve all InstallAware variables" within that file?

In the above example, TARGETDIR and VERSION are updated at install time.

Thoughts and thanks,

Chris


I am not I am understanding the problem - what is wrong with adding and removing the key to make specific changes?
Aviv Giladi
InstallAware Software

White Papers (HowTos) - http://www.installaware.com/publication ... papers.htm
Product Guides - http://www.installaware.com/publication ... guides.htm
InstallAware Help -F1 anywhere in the InstallAware IDE

ckaware
Posts: 125
Joined: Thu Mar 17, 2011 11:43 am

Re: EditXML update request...

Postby ckaware » Tue Sep 13, 2011 6:17 pm

Here's my thinking...

1.) Removing and adding the key seems like a waste of cycles (it's already there, why remove it to add it again?
2.) If an XML or a TEXT file has InstallAware variables, there's no current implementation which will modify the string in the file without manipulating the file elsewhere...
When I write to the XML file using the built in XML editing procedure, content in the XML is removed (comments etc.)
EditFile find/replace does the same thing...
Write to Text file only supports writing to a file, it doesn't support Search String/ Replace String etc.

Thanks,

Chris

giaviv
Posts: 2039
Joined: Fri Dec 17, 2010 1:39 pm

Re: EditXML update request...

Postby giaviv » Wed Sep 14, 2011 9:53 am

Chris,

Thank you. I definitely think though that even despite what you mentioned the XML support in IA is extremely powerful and can help you achieve almost everything.
Aviv Giladi
InstallAware Software

White Papers (HowTos) - http://www.installaware.com/publication ... papers.htm
Product Guides - http://www.installaware.com/publication ... guides.htm
InstallAware Help -F1 anywhere in the InstallAware IDE

giaviv
Posts: 2039
Joined: Fri Dec 17, 2010 1:39 pm

Re: EditXML update request...

Postby giaviv » Wed Sep 14, 2011 9:53 am

Chris,

Thank you. I definitely think though that even despite what you mentioned the XML support in IA is extremely powerful and can help you achieve almost everything.
Aviv Giladi
InstallAware Software

White Papers (HowTos) - http://www.installaware.com/publication ... papers.htm
Product Guides - http://www.installaware.com/publication ... guides.htm
InstallAware Help -F1 anywhere in the InstallAware IDE

ckaware
Posts: 125
Joined: Thu Mar 17, 2011 11:43 am

Re: EditXML update request...

Postby ckaware » Wed Sep 14, 2011 10:13 am

Thanks,

It's great, but will there's be a workaround for XML content removal etc?

Meaning, EditXML stripping out content from the XML file such as comments etc.

Chris

giaviv
Posts: 2039
Joined: Fri Dec 17, 2010 1:39 pm

Re: EditXML update request...

Postby giaviv » Wed Sep 14, 2011 12:35 pm

Chris,

This does not reproduce for me - comments remain intact. Could you please provide a reproducing project?
Aviv Giladi
InstallAware Software

White Papers (HowTos) - http://www.installaware.com/publication ... papers.htm
Product Guides - http://www.installaware.com/publication ... guides.htm
InstallAware Help -F1 anywhere in the InstallAware IDE

ckaware
Posts: 125
Joined: Thu Mar 17, 2011 11:43 am

Re: EditXML update request...

Postby ckaware » Tue Sep 20, 2011 9:30 am

Wow, just saw this reply.

I'll send over the project shortly.

Thanks,

Chris

cminorm
Posts: 6
Joined: Thu Jan 05, 2012 8:29 am

Re: EditXML update request...

Postby cminorm » Thu Jan 12, 2012 8:18 am

I'm having the same issue. I have an existing XML file that i'm installing and i just want to edit one element. Install aware creates a backup of the old file and removes all elements except the one i want to change. Do i need to list all elements regardless if i change them or not?

Norm

giaviv
Posts: 2039
Joined: Fri Dec 17, 2010 1:39 pm

Re: EditXML update request...

Postby giaviv » Fri Jan 13, 2012 3:29 pm

Hi,

Could you please attach a reproducing project?
Aviv Giladi
InstallAware Software

White Papers (HowTos) - http://www.installaware.com/publication ... papers.htm
Product Guides - http://www.installaware.com/publication ... guides.htm
InstallAware Help -F1 anywhere in the InstallAware IDE

cminorm
Posts: 6
Joined: Thu Jan 05, 2012 8:29 am

Re: EditXML update request...

Postby cminorm » Wed Jan 18, 2012 10:10 am

I modified the application to read and write the XML file without name spaces. Now the installer can edit the XML file.

giaviv
Posts: 2039
Joined: Fri Dec 17, 2010 1:39 pm

Re: EditXML update request...

Postby giaviv » Mon Jan 30, 2012 12:16 am

Thank you!

If you are, however, able to reproduce this please send us the project so we could take a closer look at what is happening.
Aviv Giladi
InstallAware Software

White Papers (HowTos) - http://www.installaware.com/publication ... papers.htm
Product Guides - http://www.installaware.com/publication ... guides.htm
InstallAware Help -F1 anywhere in the InstallAware IDE


Return to “Technical Support”

Who is online

Users browsing this forum: No registered users and 69 guests