<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"><channel><category>pcsoft.us.windev</category><copyright>Copyright 2026, PC SOFT</copyright><lastBuildDate>5 Mar 2018 11:26:08 Z</lastBuildDate><pubDate>5 Mar 2018 11:26:08 Z</pubDate><description>Hi forum,&#13;
&#13;
Based on the example "wd-outlook',  I have build an email -in table .  In this table I  want to show an icon 'paperclip' if there are any attachments to the mail.&#13;
&#13;
The emails are loaded into the table in the local procedure listMails&#13;
&#13;
-  EmailReadFirstHeader does not return the number of attachments in the row. The documentation states that the email structure is being used when omitting the email variable.  EmailReadFirst does return the number of attachments.  &#13;
&#13;
q1.  What's the difference between EmailReadFirstHeader and emailReadFirst? &#13;
q2.  If the difference is speed , how to return the of attachments in EmailReadFirstHeader and EmailReadNextHeader ?&#13;
&#13;
&#13;
PROCEDURE ListMails(bReadFirst = True)&#13;
&#13;
HourGlass()&#13;
&#13;
Multitask(-1)&#13;
&#13;
dTodaysDate is Date =Today()&#13;
dReceiveDate is Date&#13;
&#13;
// Displays the list of OutLook messages&#13;
TableDeleteAll(TABLE_Emails)&#13;
&#13;
IF bReadFirst = True THEN&#13;
    EmailReadFirstHeader(gnSessionId)&#13;
END&#13;
&#13;
WHILE  Email.Out = False&#13;
	&#13;
	Multitask(-1)&#13;
	//Depending on he element that is selected in "When?", add or not the email in the table&#13;
	TableAddLine(TABLE_Emails, Email.Sender,Email.Subject,Email.ReceiveDate, Email.ID, Email.NbAttach)&#13;
	EmailReadNextHeader(gnSessionId)&#13;
end</description><ttl>30</ttl><generator>WEBDEV</generator><language>en_US</language><link>https://forum.pcsoft.fr/es-ES/pcsoft.us.windev/64824-difference-emailreadfirstheader-and-emailreadfirst-number-attachments/read.awp</link><title>Difference EmailReadFirstHeader  and EmailReadFirst, number of attachments</title><managingEditor>moderateur@pcsoft.fr (El moderador)</managingEditor><webMaster>webmaster@pcsoft.fr (El webmaster)</webMaster></channel></rss>
