Skip to main content
May 2, 2008
Question

CFGridColumn Values List

  • May 2, 2008
  • 3 replies
  • 499 views
When I ran this code on my most updated cf8 box, I do not get the “dropdown” of values I used to get when I click on the state column to edit. I think the most recent update to CF8 8.0.1 may have some new EXT libraries that are corrupt or not fully capable of the previous functionality. I am going crazy and I need to have some validation that this is a bug.

You can see it in action here…. http://www.gobluecricket.com/bluecricket/cfgrid/danvegagrid2.cfm

Do you have any idea if this is a bug in CF8? Is there any technical help besides the support forums for developers like me who are using CF8?

Thanks for you time.

Vince.

--------------- Grid Test ----------------------------------------
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" " http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns=" http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Grid Test</title>
</head>


<body>
<!--- <cfquery name="getArtists" datasource="cfartgallery">
SELECT artistId, firstname, lastname, address, city, state, postalcode, email
FROM Artists
</cfquery> --->
<cfscript>
getArtists = QueryNew("artistId, firstname, lastname, address, city, state, email");
newRow = QueryAddRow(getArtists);
QuerySetCell(getArtists, "artistId", "1" );
QuerySetCell(getArtists, "FirstName", "Freddie" );
QuerySetCell(getArtists, "LastName", "Acker" );
QuerySetCell(getArtists, "address", "cowtown road" );
QuerySetCell(getArtists, "city", "gayton" );
QuerySetCell(getArtists, "state", "IL" );
QuerySetCell(getArtists, "email","james@acker.com" );
newRow = QueryAddRow(getArtists);
QuerySetCell(getArtists, "artistId", "2" );
QuerySetCell(getArtists, "FirstName","Angie" );
QuerySetCell(getArtists, "LastName", "Acker" );
QuerySetCell(getArtists, "address", "friendship road" );
QuerySetCell(getArtists, "city", "jamestown" );
QuerySetCell(getArtists, "state", "TX" );
QuerySetCell(getArtists, "email","angie@acker.com" );
// etc.
</cfscript>

<cfset args = structNew()>
<cfset args.name = "ArtistGrid">
<cfset args.format = "html">
<cfset args.query = "getArtists">
<cfset args.stripeRows = true>
<cfset args.selectColor = "##D9E8FB">
<cfset args.selectmode = "edit">
<cfset args.style="z-index:1000;">
<cfset args.onchange = "cfc:artists.editArtist({cfgridaction},{cfgridrow},{cfgridchanged})">

<cfset state_abbr = "AL,AK,AZ,AR,CA,CO,CT,DE,DC,FL,GA,HI,ID,IL,IN,IA,KS,KY,LA,ME,MD,MA,MI,MN,MS,MO,MT,NE,NV,NH,NJ,NM,NY,NC,ND,OH,OK,OR,PA,RI,SC,SD,TN,TX,UT,VT,VA,WA,WV,WI,WY">
<cfset state_name = "Alabama,Alaska,Arizona,Arkansas,California,Colorado,Connecticut,Delaware,District of Columbia,Florida,Georgia,Hawaii,Idaho,Illinois,Indiana,Iowa,Kansas,Kentucky,Louisiana,Maine,Maryland,Massachusetts,Michigan,Minnesota,Mississippi,Missouri,Montana,Nebraska,Nevada,New Hampshire,New Jersey,New Mexico,New York,North Carolina,North Dakota,Ohio,Oklahoma,Oregon,Pennsylvania,Rhode Island,South Carolina,South Dakota,Tennessee,Texas,Utah,Vermont,Virginia,Washington,West Virginia,Wisconsin,Wyoming">

<cfform>
<cfgrid attributeCollection="#args#">
<cfgridcolumn name="artistid" display="false">
<cfgridcolumn name="firstname" header="First Name">
<cfgridcolumn name="lastname" header="Last Name">
<cfgridcolumn name="email" header="Email Address">
<cfgridcolumn name="address" header="Address">
<cfgridcolumn name="city" header="City">
<cfgridcolumn name="state" header="State" width="125" select="yes" values="#state_abbr#" valuesdisplay="#state_name#" valuesdelimiter=",">
</cfgrid>
</cfform>
</body>
</html>

------------------- Artists.cfc (in the same directory as above file) ----------------------------------------------
<cfcomponent>
<cffunction name="editArtist" access="remote" returntype="string">
<cfargument name="gridaction" type="string" required="yes">
<cfargument name="gridrow" type="struct" required="yes">
<cfargument name="gridchanged" type="struct" required="yes">
<cfset myResult="foo">
<cfreturn myResult>
</cffunction>
</cfcomponent>
    This topic has been closed for replies.

    3 replies

    May 5, 2008
    Hi,

    You should soon receive a fix for this. We are working on it.

    Thanks,
    Bhakti
    Adobe ColdFusion team
    Participant
    August 28, 2008
    OK, I'm bit by this too. What is the identified issue and/or fix?

    Thanks,

    Tim
    Inspiring
    May 2, 2008
    nope, that obviously woudn't work... disregard.

    Azadi Saryev
    Sabai-dee.com
    http://www.sabai-dee.com/
    Inspiring
    May 2, 2008
    what if you change the name of affected cfgridcolumn from STATE, which
    is the name of your query column which contains a single value, to
    something different? just a guess...

    Azadi Saryev
    Sabai-dee.com
    http://www.sabai-dee.com/