I am having some issues figuring this one out. The code was all working with
ColdFusion 8, then we moved to a CF 9 server and discovered the code was no
longer working. It seems like the grid never stops loading. I have placed the
code snippets below and parts from the cfdebug window to show there is one
result displaying. I can't figure out what changed from 8 to 9. Any assistance
would be appreciated.
Main CFM file:
<cfform action="viewMsg.cfm">
<cfgrid
bind="CFC:messages.dispMessages({cfgridpage},{cfgridpagesize},{cfgridsortcolumn},{cfgridsortdirection})"
format="html" height="300" width="375" name="getMsg" pagesize="25" sort="yes"
maxrows="1" selectmode="row" tooltip="testing tooltip" delete="yes"
deletebutton="Remove Message" bindonload="yes">
<cfgridcolumn name="messages_isRead_updated"
type="string_nocase" width="45" display="yes" header="Read">
<cfgridcolumn name="messages_id" display="no"
header="MsgID">
<cfgridcolumn name="users_usernameDisp" display="yes"
header="From">
<cfgridcolumn name="messages_title" display="yes"
header="Subject">
<cfgridcolumn name="messages_date_sent" display="yes"
mask="MM DD YYYY" header="Date Sent">
</cfgrid>
<cfinput type="submit" name="getMsgs" value="View Message">
</cfform>
<cfform name="sendMsg" action="sendmsg.cfm"
method="post"> </cfform>
CFC file:
<cffunction name="dispMessages" access="remote" returntype="any">
<cfargument name="page" default="1">
<cfargument name="pageSize" default="25">
<cfargument name="gridsortcolumn" default="messages_id">
<cfargument name="gridsortdirection" default="ASC">
<cfquery name="getMessages" datasource="#REQUEST.mssqlDSN#">
select btvUser.users.users_usernameDisp,
btvUser.messages.messages_id, btvUser.messages.messages_title,
btvUser.messages.messages_date_sent,
case when btvUser.messages.messages_isRead = 0
then 'New'
else 'Old' end AS messages_isRead_updated
from btvUser.messages
left outer join btvUser.users on btvUser.users.users_id =
btvUser.messages.messages_from_users_id
where btvUser.messages.messages_to_users_id = 5
<!--- <cfif (isDefined('gridsortcolumn') AND gridsortcolumn
neq "") AND (isDefined('gridsortdirection') and gridsortdirection neq "")>
order by #ARGUMENTS.gridsortcolumn#
#ARGUMENTS.gridsortdirection#, messages_date_sent desc
<cfelse>
order by messages_id desc, messages_date_sent desc
</cfif>--->
</cfquery>
<cfreturn QueryConvertForGrid(getMessages, arguments.page,
arguments.pageSize) />
</cffunction>
CFDEBUG:
info:http: CFC invocation response:
{"QUERY":{"COLUMNS":["USERS_USERNAMEDISP","MESSAGES_ID","MESSAGES_TITLE","MESSAGES_DATE_SENT","MESSAGES_ISREAD_UPDATED"],"DATA":[["Alteria",118,"Testing
This","May, 09 2010 08:25:36","New"]]},"TOTALROWCOUNT":1}
info:http: CFC invocation response:
{"QUERY":{"COLUMNS":["USERS_USERNAMEDISP","MESSAGES_ID","MESSAGES_TO_USERS_ID","MESSAGES_TITLE","MESSAGES_DATE_SENT","MESSAGES_ISREAD"],"DATA":[["Alteria",118,5,"Testing
This","May, 09 2010 08:25:36",0]]},"TOTALROWCOUNT":1}
info:http: Replaced markup for element: myCFWindow_body
info:widget: Selected tab, id: readMessages in tab container, id: messageArea
info:widget: Created grid, id: getSentMsg
info:http: HTTP GET
messages.cfc?method=dispSentMessages&returnFormat=json&argumentCollection=%7B%22page%22%3A1%2C%22pageSize%22%3A10%2C%22gridsortcolumn%22%3A%22%22%2C%22gridsortdirection%22%3A%22ASC%22%7D&_cf_nodebug=true&_cf_nocache=true&_cf_clientid=252D76B0060B6273D425D8A95F88B2AC&_cf_rc=10
info:http: Invoking CFC: messages.cfc , function: dispSentMessages , arguments:
{"page":1,"pageSize":10,"gridsortcolumn":"","gridsortdirection":"ASC"}
info:widget: Created grid, id: getMsg
info:http: HTTP GET
messages.cfc?method=dispMessages&returnFormat=json&argumentCollection=%7B%22page%22%3A1%2C%22pageSize%22%3A25%2C%22gridsortcolumn%22%3A%22%22%2C%22gridsortdirection%22%3A%22ASC%22%7D&_cf_nodebug=true&_cf_nocache=true&_cf_clientid=252D76B0060B6273D425D8A95F88B2AC&_cf_rc=9
info:http: Invoking CFC: messages.cfc , function: dispMessages , arguments:
{"page":1,"pageSize":25,"gridsortcolumn":"","gridsortdirection":"ASC"}
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology-Michael-Dinowitz/dp/1430272155/?tag=houseoffusion
Archive:
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:333536
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm