Kinook Software Forum

Kinook Software Forum (https://www.kinook.com/Forum/index.php)
-   [VBP] General Discussion (https://www.kinook.com/Forum/forumdisplay.php?f=2)
-   -   SendMail Problem (https://www.kinook.com/Forum/showthread.php?t=1193)

AndyFarr 08-09-2005 11:34 AM

SendMail Problem
 
1 Attachment(s)
I am getting the following error when trying to send the Fail Message produced when a Vs.Net C# Project Fails to build

Error expanding macros in property Message:

The only macro in the message contains the text output from the VS.Net Build Step. Any Ideas what Could be causing the problem ?

Text from macro in attached File

Thanks

Andy

kinook 08-09-2005 11:46 AM

How is the macro referenced by the step being created? Can you post or send a .bld file that demonstrates the problem? If you use the FAILSTEP_OUTPUT/LASTSTEP_OUTPUT system macros, any characters that VBP treats specially (%, [, and ]) will normally be doubled to be treated as literal characters. Somehow, the macro that you are referencing contains non-doubled bracket chars which VBP is trying to evaluate as script code.

AndyFarr 08-09-2005 12:03 PM

Calling Method
 
The SendMail is part of a Subroutine and the LASTSTEP_OUTPUT is copied to a Temporary macro as a parameter so I assume that the Special characters have not been doubled up in the copy.

Any way that I can solve this ?

kinook 08-09-2005 12:17 PM

At the place where you're referencing %LASTSTEP_OUTPUT%, use

[vbld_EscapeString("%LASTSTEP_OUTPUT%")]

instead

AndyFarr 08-10-2005 03:50 AM

Still Fails
 
It fails on the Macro call with an "Unterminated String Constant" error Line 1 Character 37

This would appear to be a LineFeed 0x0A character. I wonder is the macro only interprates CRLF pairs I know some VB stuff fails on standalone LF charaters but this is the output from DEVENV so I have litle control over it.

Thanks for your support

Andy

kinook 08-10-2005 07:19 AM

Duh, my test string didn't have multiple lines. In that case, use this instead:

[vbld_EscapeString(vbld_AllMacros()("LASTSTEP_OUTPUT").Value)]

AndyFarr 08-10-2005 08:58 AM

Thanks
 
That's sorted it.

Andy


All times are GMT -5. The time now is 08:46 AM.


Copyright © 1999-2023 Kinook Software, Inc.