<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>classical report &#8211; SAP EWM Help</title>
	<atom:link href="https://www.sapewmhelp.com/question-tag/classical-report/feed/" rel="self" type="application/rss+xml" />
	<link>https://www.sapewmhelp.com</link>
	<description>SAP EWM questions answered by experts — ABAP, S/4HANA, warehouse management</description>
	<lastBuildDate>Sun, 03 Aug 2025 06:54:31 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=7.0.2</generator>
	<item>
		<title>Classical Report Events in SAP ABAP</title>
		<link>https://www.sapewmhelp.com/question/classical-report-events-in-sap-abap/</link>
					<comments>https://www.sapewmhelp.com/question/classical-report-events-in-sap-abap/#respond</comments>
		
		<dc:creator><![CDATA[DPM125]]></dc:creator>
		<pubDate>Sun, 03 Aug 2025 06:54:31 +0000</pubDate>
				<guid isPermaLink="false">https://www.sapewmhelp.com/?question=classical-report-events-in-sap-abap</guid>

					<description><![CDATA[Classical Reports in ABAP use a sequence of predefined events during program execution. These events let you structure your code based on data fetching, formatting, and output rendering. Event Description LOAD-OF-PROGRAM Triggered once when the program is loaded into memory (before anything else) INITIALIZATION Called before the selection screen is displayed AT SELECTION-SCREEN Called after [&#8230;]]]></description>
										<content:encoded><![CDATA[<p>Classical Reports in ABAP use a sequence of predefined events during program execution. These events let you structure your code based on data fetching, formatting, and output rendering.</p>
<table>
<thead>
<tr>
<th>Event</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><code>LOAD-OF-PROGRAM</code></td>
<td>Triggered once when the program is loaded into memory (before anything else)</td>
</tr>
<tr>
<td><code>INITIALIZATION</code></td>
<td>Called before the selection screen is displayed</td>
</tr>
<tr>
<td><code>AT SELECTION-SCREEN</code></td>
<td>Called after user input is entered on the selection screen</td>
</tr>
<tr>
<td><code>START-OF-SELECTION</code></td>
<td>Main logic block, starts after selection screen input</td>
</tr>
<tr>
<td><code>TOP-OF-PAGE</code></td>
<td>Used to print page headers</td>
</tr>
<tr>
<td><code>END-OF-PAGE</code></td>
<td>Used to print page footers</td>
</tr>
<tr>
<td><code>END-OF-SELECTION</code></td>
<td>Called after START-OF-SELECTION, typically for final output</td>
</tr>
<tr>
<td><code>AT LINE-SELECTION</code></td>
<td>Triggered by user double-click (F2) on output</td>
</tr>
<tr>
<td><code>AT USER-COMMAND</code></td>
<td>Triggered when a custom function key is pressed</td>
</tr>
</tbody>
</table>
<div class="hcb_wrap">
<pre class="prism line-numbers lang-python" data-lang="Python"><code><!--StartFragment --><span><span>REPORT </span>zrep_lclclass<span>.</span>

<span>TABLES</span><span>: </span>mara<span>.</span>
<span>data</span><span>: </span>lt_mara <span>type </span><span>table </span><span>of </span>mara<span>.</span>

<span>" Selection Screen</span>
<span>SELECT-OPTIONS</span><span>: </span>s_matnr <span>FOR </span>mara<span>-</span>matnr<span>.</span>

<span>" LOAD-OF-PROGRAM</span>

<span>LOAD-OF-PROGRAM</span><span>.</span>
  <span>WRITE</span><span>: </span>/ '&gt;&gt; <span>Program </span>loaded <span>into </span><span>memory</span><span>.</span>'<span>.</span>

  <span>" INITIALIZATION</span>

<span>INITIALIZATION</span><span>.</span>
  s_matnr<span>-</span><span>sign   </span><span>= </span>'I'<span>.</span>
  s_matnr<span>-</span>option <span>= </span>'EQ'<span>.</span>
  s_matnr<span>-</span>low    <span>= </span>'1'<span>.</span>
  s_matnr<span>-</span>high <span>= </span>'9999'<span>.</span>
  <span>APPEND </span>s_matnr<span>.</span>

  <span>" AT SELECTION-SCREEN</span>

<span>AT </span><span>SELECTION-SCREEN</span><span>.</span>
  <span>IF </span>s_matnr[] <span>IS </span><span>INITIAL</span><span>.</span>
    <span>MESSAGE </span>'Please enter a carrier ID' <span>TYPE </span>'E'<span>.</span>
  <span>ENDIF</span><span>.</span>

  <span>" START-OF-SELECTION</span>

<span>START-OF-SELECTION</span><span>.</span>
  <span>WRITE</span><span>: </span>/ '&gt;&gt; Start <span>of </span>selection'<span>.</span>
  <span>SELECT </span>* <span>FROM </span>mara <span>INTO </span><span>TABLE </span>lt_mara
  <span>WHERE </span>matnr <span>IN </span>s_matnr<span>.</span>

  <span>IF </span>sy<span>-</span>subrc <span>= </span><span>0</span><span>.</span>
    <span>LOOP </span><span>AT </span>lt_mara <span>INTO </span><span>DATA</span><span>(</span>ls_matnr<span>)</span><span>.</span>
      <span>WRITE</span><span>: </span>/ ls_matnr<span>-</span>matnr<span>,</span>
               ls_matnr<span>-</span>ernam<span>,</span>
               ls_matnr<span>-</span>ersda<span>.</span>
    <span>ENDLOOP</span><span>.</span>
  <span>ELSE</span><span>.</span>
    <span>WRITE</span><span>: </span>/ 'No <span>data </span>found'<span>.</span>
  <span>ENDIF</span><span>.</span>

  <span>" END-OF-SELECTION</span>

<span>END-OF-SELECTION</span><span>.</span>
  <span>WRITE</span><span>: </span>/ '&gt;&gt; <span>End </span><span>of </span>selection processing<span>.</span>'<span>.</span>

  <span>" TOP-OF-PAGE</span>

<span>TOP-OF-PAGE</span><span>.</span>
  <span>WRITE</span><span>: </span>/ 'Material Master Report'<span>.</span>
  <span>WRITE</span><span>: </span>/ '<span>-</span>-<span>-</span>-<span>-</span>-<span>-</span>-<span>-</span>-<span>-</span>-<span>-</span>-<span>-</span>-<span>-</span>-<span>-</span>-<span>-</span>-<span>-</span>-'<span>.</span>

  <span>" AT LINE-SELECTION</span>

<span>AT </span><span>LINE-SELECTION</span><span>.</span>
  <span>MESSAGE </span>'You clicked a line!' <span>TYPE </span>'I'<span>.</span></span> </code></pre>
<p>Output:<br />
Execute<br />
<img decoding="async" class="content-img" src="https://www.sapewmhelp.com/wp-content/uploads/2025/08/classical-rep-event.png" /></p>
<p><img decoding="async" class="content-img" src="https://www.sapewmhelp.com/wp-content/uploads/2025/08/classical-rep-event2.png" /><br />
<img decoding="async" class="content-img" src="https://www.sapewmhelp.com/wp-content/uploads/2025/08/classical-rep-event3.png" /></p>
</div>
]]></content:encoded>
					
					<wfw:commentRss>https://www.sapewmhelp.com/question/classical-report-events-in-sap-abap/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
	</channel>
</rss>
