Thanks. In my case I was trying to log table data queried before and after
formatting for debugging purposes. Do you think others might have a similar
need? If so, do you think an overload for Log to disable formatting could be a
good thing?
Jason Ginchereau <[EMAIL PROTECTED]> wrote:
The Session.Log() method passes the message string to to
MsiProcessMessage as the format-string (field 0) of a Record, so it gets
automatically formatted there. To avoid that behavior, you can do something
like this:
using (Record rec = new Record(1))
{
rec.FormatString = "[1]";
rec[1] = msg;
session.Message(InstallMessage.Info, rec);
}
Or you can escape the brackets like this:
session.Log(@"[\[]Not a property[\]]");
From: Christopher Painter [mailto:[EMAIL PROTECTED]
Sent: Monday, May 19, 2008 8:37 AM
To: Jason Ginchereau; [EMAIL PROTECTED]; wix-users@lists.sourceforge.net
Subject: RE: [WiX-users] DTF in WiX
I'm working on a sample for my blog right now. In doing so, I've noticed
something. It seems that session.Log() method automatically formats the text.
For example I want to do something like
// Property A = 21
// Property B = 2
string expression = "[A]*[B]"; //Really comes from table data
session.Log( "MyCA: Found Expression: " + expression );
string formattedExpression = session.Format( expression );
session.Log ("MyCa: Expression Formats as: " + formattedExpression );
But when I look at my logfile, both lines say 21*2 instead of [A]*[B] and
21*2.
Make sense? I'm wondering if there is a way to log the data found without
formatting it.
Jason Ginchereau <[EMAIL PROTECTED]> wrote:
Yes, a VS project template for a managed custom action is something we've
talked about that would be nice to do. In general I want to work on some richer
CA samples in the coming months.
From: Christopher Painter [mailto:[EMAIL PROTECTED]
Sent: Friday, May 16, 2008 7:39 PM
To: Jason Ginchereau; [EMAIL PROTECTED]; wix-users@lists.sourceforge.net
Subject: Re: [WiX-users] DTF in WiX
Sorry, one more question. How do you feel about WiX registering a new
project type in Visual Studio? A sample C# class that includes the right
references and plumbing to build the class and wrap it into a CA package
assembly?
Jason Ginchereau <[EMAIL PROTECTED]> wrote:
1) Yes, full support for the new functionality added in MSI 4.5 is
near the top of my list of things to work on in DTF. I have briefly looked at
the embedded external-UI feature, and I don't forsee any unusual technical
challenges to enabling embedded external-UI in managed code.
2) Oh, I guess that sample code in the doc is out of date.
Properties are accessed as an indexer directly on the session object. The CHM
reference topic for the Session class (Item Property) and the actual sample
ManagedCA project are correct.
3) DTF samples are included in the WiX sources (src/dtf/Samples) but
not in WiX3.msi.
4) Umm, grapefruit juice. Seriously. :)
Thank you for reporting these issues. I hope you find DTF useful.
-Jason-
From: Christopher Painter [mailto:[EMAIL PROTECTED]
Sent: Friday, May 16, 2008 1:25 PM
To: Jason Ginchereau; [EMAIL PROTECTED]; wix-users@lists.sourceforge.net
Subject: Re: [WiX-users] DTF in WiX
I have a few other questions for you if you don't mind.
1) Will DTF have support for authoring MSI 4.5 style Embedded External
UI handlers?
2) The Sample C# custom action references a Session.Property[ string
Property ] but when I add the reference and using statement I get an error
that that Session doesn't have a definition for Property. Am I pulling in the
wrong reference or something?
3) The CHM topic references a Samples\ManagedCA directory. I don't see
it?
4) What's your favorite beverage?
Jason Ginchereau <[EMAIL PROTECTED]> wrote:
Looks like Errors.resources.resources got ignored by by the zip which
is supposed to pickup all the sources, because of the .resources file
extension. I'll fix it for the next build.
Meanwhile you can create that file by running resgen.exe on Errors.txt.
(I should probably make that happen during the project build anyway.) Or you
can build without it, but you'll get resource exceptions instead of error
messages if you encounter any errors in cabinet creation/extraction.
-Jason-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of
Christopher Painter
Sent: Friday, May 16, 2008 11:42 AM
To: [EMAIL PROTECTED]; wix-users@lists.sourceforge.net
Subject: Re: [WiX-users] DTF in WiX
I also pulled the sources but I can't get the Compression.Cab project
in the DTF solution to build. It's missing the file Errors.resources.resources
file. If I exclude it from the project it seems to build fine though.
Christopher Painter <[EMAIL PROTECTED]> wrote:
I'm was reading DTF.chm and it looks really fabulous. I want to play
with it right now but I don't see MakeSfxCA.exe. Am I missing something?
-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users
-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users
-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users
-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users