Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

cfgridsortcolumn

Engaged ,
Jul 31, 2008 Jul 31, 2008
I'm really new to CFCs and CF8 in general, and I am trying to create a grid that reads from a query result set called from another file (both a CFC and a .cfm file). When I use the CFC in IE I get an error saying an exception was thrown and not caught, and no employees show up, but the query definitely returned the right info, because it shows up fine if I look at the cfdebug window. When I use the CFC in Firefox with Firebug I get no JS errors, but also no employees show up. If I look at the logs, it looks like cfgridsortcolumn is undefined in the CFC. It's default value is NULL, so how can it possible be undefined? Is there something else going on here? When I use the URL it works fine. When I move these files to a different folder in a different branch, both URL and CFC work fine.

Any ideas? Thanks!
TOPICS
Getting started
790
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Jul 31, 2008 Jul 31, 2008
Scope your variables here:
<cfif gridsortcolumn neq "" or gridsortdirection neq "">
ORDER BY #gridsortcolumn# #gridsortdirection#

Also, what do you think will happen if one of those variables is an empty string and the other is not?
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Engaged ,
Jul 31, 2008 Jul 31, 2008
http://livedocs.adobe.com/coldfusion/6/Developing_ColdFusion_MX_Applications_with_CFML/UDFs4.htm#116...

But I scoped them anyway and turned that line to

<cfif arguments.gridsortcolumn neq "">
ORDER BY #gridsortcolumn# <cfif arguments.gridsortdirection neq "">#gridsortdirection#</cfif>

Same problem. No improvement.
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Jul 31, 2008 Jul 31, 2008
quote:

Originally posted by: kodemonki
http://livedocs.adobe.com/coldfusion/6/Developing_ColdFusion_MX_Applications_with_CFML/UDFs4.htm#116...

But I scoped them anyway and turned that line to

<cfif arguments.gridsortcolumn neq "">
ORDER BY #gridsortcolumn# <cfif arguments.gridsortdirection neq "">#gridsortdirection#</cfif>

Same problem. No improvement.

Ask yourself what will happen if gridsorcolumn is an empty string.
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Advocate ,
Jul 31, 2008 Jul 31, 2008
LATEST
Hi,

Do you have the Coldfusion 8's Ajax debugger window on?.. If so what error message it shows?...

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources