School Assignment? Project Due Tomorrow? Chat LIVE With A Programming Expert!

Welcome to Dream.In.Code
Become an Expert!

Join 300,459 Programmers for FREE! Get instant access to thousands of experts, tutorials, code snippets, and more! There are 1,628 people online right now. Registration is fast and FREE... Join Now!




CFImage Invalid ICC Profile

 

CFImage Invalid ICC Profile

xheartonfire43x

10 Jun, 2009 - 12:26 PM
Post #1

D.I.C Regular
***

Joined: 22 Dec, 2008
Posts: 260



Thanked: 2 times
My Contributions
I am building a photo gallery that displays images in rows of four after running them through a small resizing function. After the fourth image I get an error saying:
QUOTE

An exception occurred while trying to read the image.
javax.imageio.IIOException: Invalid icc profile: duplicate sequence numbers


I have no idea what the icc profile is so someone please help.

CODE

<cfdirectory action="list" directory="#localphotodir#" name="PhotoDirectory" listinfo="all" type="file" recurse="no">
<cfinclude template="/common/incl_nav.cfm">
<cfdump var="#PhotoDirectory#" expand="no">

<table cellpadding="3" cellspacing="3" border="0" align="center">
    <thead>
      <tr>
        <th colspan="4"><cfoutput>#listFirst(url.folder,"_")#'s Photos</cfoutput></th>
    </tr>
  </thead>
  <tbody>
    <tr>
            <cfset col = 1>
            <cfoutput query="PhotoDirectory">
                <cfif col MOD 4 EQ 1>
          <tr align="center">
          <cfset col = 1>
        </cfif>
                    <cfscript>
            IMGPath = photopath & listFirst(url.folder,"\") & "/" & photodirectory.name;
            Thumb = ImageNew(IMGPath);
            ImageResize(Thumb,"100","");
          </cfscript>
          <cfdump var="#imgpath#">
          <td align="center">
            <cfimage source="#thumb#" action="writetobrowser">
            
          </td>
          <cfset col = col + 1>
          <cfdump var="#col#">
         <cfif col MOD 4 EQ 1>
             </tr>
         </cfif>
      </cfoutput>



Also here is a simpler one:
I want to split the cfdirectory query into groups of 10 so tat I can display only ten on each page. Does anyone know how to do that. Use the same code as above for the example.

User is offlineProfile CardPM
+Quote Post

Fast ReplyReply to this topicStart new topic

Time is now: 11/8/09 02:13AM

Live Help!

Be Social

Dream.In.Code RSS Feed Dream.In.Code LinkedIn Group Follow Us On Twitter Fan Us On Facebook

Tutorials

Programming

Web Development

Reference Sheets

Code Snippets

DIC Chatroom

Bye Bye Ads

Monthly Drawing

Thumb Drive

Top Contributors

Top 10 Kudos This Month