Home » Developer & Programmer » Forms » read Special image
read Special image [message #137118] Tue, 13 September 2005 06:26 Go to next message
rzkhan
Messages: 370
Registered: March 2005
Senior Member
Hi there..
Could I read a special image (no-photo.gif) into image item when there is no image available for the selected record.
the rest works fine as
DECLARE 
	  gif_image_dir VARCHAR2(80) := 'e:\m\'; 
	  photo_filename VARCHAR2(80); 
	  
BEGIN 

	:System.Message_Level := '25';

	photo_filename := gif_image_dir||LOWER(:all_students.rn)||'.gif'; 
	READ_IMAGE_FILE(photo_filename, 'GIF', 'all_students.image6');
	
	--if :all_students.rn<> gif_image_dir||LOWER(:all_students.rn)||'.gif' then 
	   IF NOT FORM_SUCCESS THEN
	   	    photo_filename :='e:\m\no-photo.gif'; 
	   	    READ_IMAGE_FILE(photo_filename, 'GIF', 'all_students.image6');
	   	 --   MESSAGE('This student does not have a photo on file.');
	   END IF;
	   :SYSTEM.MESSAGE_LEVEL := '0';
--end if;
END; 



Thanks
Riaz
Re: read Special image [message #137209 is a reply to message #137118] Tue, 13 September 2005 18:47 Go to previous message
djmartin
Messages: 10181
Registered: March 2005
Location: Surges Bay TAS Australia
Senior Member
Account Moderator
We are missing the intent of your question.

Does your code work? That is, if there is no photo for a particular student id, does the form_failure fire for you.

David
Previous Topic: on-error trigger does not trap ORA-28002
Next Topic: how can we make fast search in large no. of records?
Goto Forum:
  


Current Time: Fri Sep 20 01:56:07 CDT 2024