Page 1 of 1 1
Topic Options
#197782 - 2010-02-15 02:32 PM Outlook Signature
Christof Offline
Fresh Scripter

Registered: 2003-04-10
Posts: 35
Loc: Ornbau, Frankonia, Germany
Hello!

I used the script in this topic to create the Outlook signature for my network. But I have a problem in understanding something.

The script skips null lines, but with this I have problems. The skipping is only working if I use kix32.exe, but not with wkix32.exe. That is my first problem.

The next, what I don't understand, is WHY the lines are skipped. The code for that is:
If $ $ ? EndIf

Of for better understanding:
If $
$ ?
EndIf

Why are the lines skipped with this code? As example, my template contains the following line:
&COMPANY&<br>

When &COMPANY& is replaced with an empty string, in the $-variable should remain:
<br>

But when I execute the script with kix32.exe, the string is empty and so it will not be processed by the if-statement, but if I execute it with wkix32.exe, it contains <br>. Why?

The behaviour with wkix32.exe is logical, but with kix32.exe it's unlogical, but it does, what we want. Can someone explain me this behaviour?


I changed the script, that I can also process txt- and rtf-templates. It works, but there is the problem with empty lines much bigger.

Bye


Edited by Christof (2010-02-15 02:35 PM)

Top
#197783 - 2010-02-15 03:40 PM Re: Outlook Signature [Re: Christof]
Glenn Barnas Administrator Offline
KiX Supporter
*****

Registered: 2003-01-28
Posts: 4401
Loc: New Jersey
The posted code - by design - should skip blank lines and lines with variables that are empty. You need to create your template accordingly. If you want a blank line where the company name would go, you need to put the <BR> tag on a line by itself, after the &COMPANY& line.

The purpose behind this is for data objects such as "cell phone" - not everybody has one, so - a template field of "&CELLPHONE& (Cell)" would not put anything in the signature, as opposed to an empty line with "(Cell)".

Since HTML will join lines not separated with <P> or <BR> tags, this allows you to specifiy fields that are optional.

I've not seen the problem with WKIX32 vs KIX32 - I'll give it a try and see if I can reproduce the problem.

Glenn
_________________________
Actually I am a Rocket Scientist! \:D

Top
Page 1 of 1 1


Moderator:  Glenn Barnas, NTDOC, Arend_, Jochen, Radimus, Allen, ShaneEP, Ruud van Velsen, Mart 
Hop to:
Shout Box

Who's Online
0 registered and 837 anonymous users online.
Newest Members
M_Moore, BeeEm, min_seow, Audio, Hoschi
17883 Registered Users

Generated in 0.053 seconds in which 0.025 seconds were spent on a total of 13 queries. Zlib compression enabled.

Search the board with:
superb Board Search
or try with google:
Google
Web kixtart.org