[D
	/LoadSW [P
		[A LoadFlag Mode]	% LoadFlag = False -> Check only if Files are existing 	

			/ApplSWFileName 'ApplSWEasySteps_' def
			/ApplTreeFileName 'ApplTrEasySteps_' def

    	/Result #1 def
   		/MissingFile '' def	
			
			/SWFile FilePath ApplSel.ApplDir add '\' add ApplSWFileName add EloTypeExt add def
			/SWFile SWFile '_V' add ApplSel.ApplSWVersion cvs add 'S' add ApplSel.ApplSWSubVersion cvs add def 
			ApplSel.ApplSWBetaInfo '' ne [B
				/SWFile SWFile '_' add ApplSel.ApplSWBetaInfo add def
			] if
			Mode [B
			  0 [B /SWFile SWFile '.HX2' add def ]   
			  1 [B /SWFile SWFile '.HX3' add def ]   			
			] [B
			] case  

			
			
			/TreeFile FilePath ApplSel.ApplDir add '\' add ApplTreeFileName add  EloTypeExt add EasyStepsParExt add def
			/TreeFile TreeFile '_V' add ApplSel.ApplTreeVersion cvs add 'S' add ApplSel.ApplTreeSubVersion cvs add def 
			MCTreeBetaInfo '' ne [B
				/TreeFile TreeFile '_' add ApplSel.ApplTreeBetaInfo add def
			] if
			/TreeFile TreeFile '.HX2' add def

			/DefaultParFile FilePath ApplSel.ApplDir add '\' add ApplTreeFileName add EloTypeExt add EasyStepsParExt add def
			/DefaultParFile DefaultParFile '_V' add ApplSel.ApplTreeVersion cvs add 'S' add ApplSel.ApplTreeSubVersion cvs add def 
			ApplSel.ApplTreeBetaInfo '' ne [B
				/DefaultParFile DefaultParFile '_' add ApplSel.ApplTreeBetaInfo add def
			] if
			/DefaultParFile DefaultParFile '.GR3' add def


			% check if files are existing
			Result [B
				SWFile FileExist not [B
					/Result #0 def 
					/MissingFile SWFile def
				] if
			] if
			Result [B
				TreeFile FileExist not [B
					/Result #0 def 
					/MissingFile TreeFile def
				] if
			] if
			Result [B
				DefaultParFile FileExist not [B
					/Result #0 def 
					/MissingFile DefaultParFile def
				] if
			] if

			Result LoadFlag and [B
				'Erasing application firmware sector...' log     
				4 TalkIntf.ClearInstanceAll
				'Downloading application software...' log
				Mode [B
				  0 [B SWFile dup loadobj exch PackInst:DownloadHX2File	]
				  1 [B SWFile dup loadobj exch PackInst:DownloadHX3File	]
		    ] [B
		    ] case 	  
				'Downloading application parameter tree...' log     		
		    	TreeFile dup loadobj exch PackInst:DownloadHX2File		
				'Updating UPID list...' log
		    	TalkIntf.UpdateUPIDList       
				'Downloading application default parameters...' log
				DefaultParFile dup loadobj exch PackInst:DownloadGR3File					
			] if
	   	[A /MissingFile /Result]
   	] 
]