cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
ChristopheOce
Level 7

SprintfMsiLog doesn't write anything !?

Hi,

I work with installshield 2008 (basic msi project)
i'd like to place some information in my custom action (install script code) and on internet i've found this link :

http://www.macrovision.com/webdocuments/PDF/msi_writing_to_the_log_file.pdf?link_id=productsTipsTricks

on my project i have a custom action (installscript) who is execute in the user interface when a user click on next :



****** other code **********
SprintfMsiLog("custom action executee !");


but if i launch my file msi in a command prompt with this parameter : /l*v c:\log.txt i can't see anything in the log file about => custom action executee !!!

Have you got any idea what happens ?

Thanks
Christophe
Labels (1)
0 Kudos
(3) Replies
ChristopheOce
Level 7

I'm sorry but i think it was an error than me ! !

now i've place the custom action in the sequence as the sample => launch condition and on the log file i can see my sentence !

sorry
Christophe
0 Kudos
joshstechnij
Level 10 Flexeran
Level 10 Flexeran

To write to the MSI log, SprintfMsiLog uses the MsiProcessMessage API. This API does not work from custom actions launched through DoAction events. More information can be found in the following MSDN Windows Installer chat transcript:
http://msdn2.microsoft.com/en-us/chats/bb332322.aspx
0 Kudos
ChristopheOce
Level 7

Hi joshstechnij,

thanks you for your information and the link !

Have a nice day
Christophe
0 Kudos