CFFGRIDS/CFGRIDCOLUMNS?

Honestly Abobe why would you give the CFGRID an HTML format
if date mask, dataAlign, currency and number format won't work. I
have tried everything I have followed all the instructions so if
anyone in this forum has a way of formating CFGRIDCOLUMNS for
aligning data, date formating to "mm/dd/yy" and DollarFormat, hell
I'm all ears because it has proven impossible for me. I'm not
trying to bash on coldfusion but if they are going to implement
something they should do it correctly did they not think that
developers which built reports would like to built them in HTML and
align and format their data too.

Thank you for the response, I didn't see that there was a newer hotfix released afterwards that I hadn't tried. Unfortunately since I didn't have time to wait for a solution I was forced to change my code and remove the inline updateable grids. I'm not sure I trust them enough now to try again later, but if the occassion arises I may attempt again.

Similar Messages

  • How to limit number of chars in a CFGRIDCOLUMN

    Hi,
    I have a 2 column grid populated from a query. The grid is
    editable and will be submitted to an action page for database
    Delete, Insert, or Update. The first grid column corresponds to a
    MS SQL database column that is defined as varchar(3).
    Currently, if the user inputs 4 characters and submits, I get
    a SQL trunc error.
    There has to be a way to limit the number of characters in
    this cfgridcolumn to 3? How is it done?

    Well, you could check the number of characters on your action
    page, and bounce them back if it exceeds the maximum number, and
    you can "protect" the database by including a limiting function on
    the data in the insert statement, like LEFT(col, 3) so that
    regardless what they specify, you will only insert the first 3 into
    the database. You really should let them know if they entered too
    many, however.
    Phil

  • Value shown in cfgridcolumn but not in cfinput

    Hi all
    I have two queries, the first one to select all information about companies from the database to show in my cfform and cfgrid and the second one to display a list of sectors that I use in a select. They both work fine.
    company.sectorid is an integer to represent a sector name and this value is "connected" to sector.sectorid where there is a column called sector.sector that has the name of the sector. 
    I can show the names of the sector in cfgridcolumn (using SECTOR).
    I can also output the sectorid (integer) in a cfinput. However, I cannot seem to output the sector (name) in the cfinput. I have tried using sector instead of sectorid in the field but to no avail. Why does it show the name correctly in the cfgridcolumn but as an integer in the cfinput? Thank you
    <!--- -QUERIES -->
    <cfquery name="qNames" datasource="sales">
        select * from COMPANY, sector
    where COMPANY.sectorid = sector.sectorid
    <cfif structKeyExists(url,"sectorID")>
    and sector.sectorid = #url.sectorid#
    </cfif>
    </cfquery>
    <CFQUERY name="sector" datasource="sales">
    SELECT sectorId, sector
    FROM sector
    ORDER BY sector
    </CFQUERY>
    <!--- OUTPUT SELECTED COLUMNS IN CFGRID--->
    <cfform format="flash" skin="haloorange">
       <cfgrid name="UsersGrid" format="flash"
             query="qNames" width="1000" rowheaders="No"
    onchange="for (var i:Number = 0; i<STATE.length; i++) {if (STATE.getItemAt([i]).data == UsersGrid.selectedItem.STATE)
    STATE.selectedIndex = i} for (var i:Number = 0; i<MEETINGTIME.length; i++) {if (MEETINGTIME.getItemAt([i]).data ==
    UsersGrid.selectedItem.MEETINGTIME) MEETINGTIME.selectedIndex = i}
    for (var i:Number = 0; i<DEPT.length; i++) {if (DEPT.getItemAt([i]).data == UsersGrid.selectedItem.DEPT)
    DEPT.selectedIndex = i}
    for (var i:Number = 0; i<CITY.length; i++) {if (CITY.getItemAt([i]).data == UsersGrid.selectedItem.CITY)
    CITY.selectedIndex = i}">
    <cfgridcolumn name="RANKING" width="50"header="Rank">
    <cfgridcolumn name="COMPANY" width="150" header="Company">
    <cfgridcolumn name="DEPARTMENT" width="150" header="Department" display="true">
    <cfgridcolumn name="FIRSTNAME" width="150" header="Contact Name">
    <cfgridcolumn name="POS" header="Position" width="160" display="true">
    <cfgridcolumn name="SECTOR" width="120" header="SECTOR" display="TRUE">
       </cfgrid>
    <!--- THE CFINPUT--->
    <cfformgroup type="tabnavigator" width="1000">
    <cfformgroup type="page" label="Details: #dateFormat(now(), 'mmm dd, yyyy')# : #qNames.RecordCount# Companies">
        <cfformgroup type="horizontal">
    <cfinput type="TEXT" name="SECTORID" label="Sector" required="yes" width="200" bind="{UsersGrid.dataProvider
    [UsersGrid.selectedIndex]['SECTORID']}" onChange="UsersGrid.dataProvider.editField(UsersGrid.selectedIndex, 'SECTORID',
    SECTORID.text);">
    </cfformgroup>

    I worked it out by making sure that all the fields in the database tables had different names, the flash can't handle the same column names in different tables. I then used cfdump to see which fields were being output and used them in my cfgrid headers. Now works fine.

  • Is it possible to add HTML inside of a cfgridcolumn

    Hello All,
    I have been searching extensively for an answer, but have
    not yet found it and figured I would post here. Thanks to everyone
    who takes the time with this :).
    My question is this: Is it possible to add HTML to a
    cfgridcolumn?
    My form looks something like this:
    <cfform format="flash" etc..>
    <cfgrid name="mygrid" quer="myquery">
    <cfgridcolumn name="aColumn" heade="myHeader">
    </cfgrid>
    </cfform>
    I have been using Actionscript to adjust the height of the
    column since I am appending multiple columns into one. I can add
    new breaklines and do word-wrapping. The code looks like this:
    function formOnLoad(){
    contactList.variableRowHeight = true;
    contactList.getColumnAt(2).labelFunction = setLabel;
    contactList.getColumnAt(2).wordWrap = true;
    function setLabel(item:Object, columnName:String): String {
    return item.companyName + '\n' + item.description +
    '\n\nMember Since: ' + item.memberSince;
    All I want to do is have a link in the grid (for example I
    want the Company Name to be "clickable" by the user), much like the
    Developer Exchange grid in
    the
    Adobe website.
    Any help would be appreciated.

    Hi,
    if you don't have more tha one clicable event per row, just
    use the row to fire the click event and open the link that way.
    Otherwise, i have no idea what the allowed tags are in a grid
    cell.
    sorry
    tim

  • CFGRIDCOLUMN combobox

    Hi all
    I have a bog-standard CFGRID that has one column which is a combobox. For some reason the combobox is displaying the value (an integer) rather than the text.
    This is my code:
    //This is the function that calls up the values for the combo box
    <cfinvoke component="#application.comlib#.global" method="Get_Divisions" returnvariable="Get_Divisions">
    <cfset lstDivID = ValueList(Get_divisions.divid)>
    <cfset lstDivisions = ValueList(Get_divisions.division)>
    //This is the grid
    <Cfform name="fCategories">
         <cfgrid pagesize="20"
          name="CategoryGrid"
          format="HTML"
          bind="cfc:#application.comlib#.admin.Categories_Get({cfgridpage},{cfgridpagesize},{cfgrid sortcolumn},{cfgridsortdirection})"
          onchange="cfc:#application.comlib#.admin.Categories_Edit({cfgridaction},{cfgridrow},{cfgr idchanged})"
          title="Categories"
          collapsible="true"
          selectmode="edit"
          delete="yes"
          insert="true"
          autowidth="true">
             <cfgridcolumn name="catid" display="no" />
             <cfgridcolumn name="divid" header="Division" type="combobox" valuesdisplay="#lstDivisions#" values="#lstDivID#"  />
             <cfgridcolumn name="category" header="Category"  />
             <cfgridcolumn name="style_suffix" header="Style Suffix" />
             <cfgridcolumn name="deleted" header="Deleted"  type="boolean" />
       </cfgrid>
    </Cfform>
    The query that returns the grid content basically looks like this:
    SELECT catid, divid, category, style_suffix, deleted FROM categories
    where divid is an integer.
    When you click on the division column, the combo box renders correctly... it changes to a text value (division from lstDivisions). But if you are not actually in the cell, it displays the integer value (divid from lstDivID)
    Am I missing something basic here?
    **EDIT**
    This problem was apparently fixed in CF 8 using a hotfix as outlined here: http://kb.adobe.com/selfservice/viewContent.do?externalId=kb403597&sliceId=2
    We're using CF9.0.1 though....
    Thanks
    Neal
    Message was edited by: Endboss_ZA

    Sorry but no.. that was some weird artifact of pasting the code.
    It looks like what I have described is a "feature", not a "bug". If this is true (and I hope it is not) then it is amazing that the CF developers did not forsee a need for the CFGRID to be used in tables that have foreign keys. What is the point of the valuesdisplay attribute if it does not work?

  • Cfselect within a cfgridcolumn

    Is there a way to combine a <cfselect> within a <cfgridcolumn> in a <cfgrid> table?
    Here's what I'm looking to do.  I would have a <cfgrid> with First Name, Last Name and then a column with States.  The States column within the <cfgrid> would be popluated by a query listing all the states.
    <cfgrid>
    First Name     Last Name    State
    John               Doe              AL  (dropdown list of states)
    Jane               Doe              MO (dropdown list of states)
    </cfgrid>

    You can't do it with a key. You have to use the little magnifier thing to get the cursor to the left of the letter. Put your finger on the word, and hold it for a moment, and small magnifying glass appears. You can the roll your finger to get the cursor to move.

  • Multiple colors in cfgridcolumn

    I need to display two different colors in a cfgridcolumn if
    the due date is less than the current date; for example, black
    color in the due date and red color in the number of past due day.
    I tried to use setStyle and setPropertiesAt function to change the
    color; however, I do not have luck. Anyone has ideas to set two
    colors in one grid column?
    01/12/2003 (1354 days past due)
    10/20/2006
    Thanks,
    Daniel

    Have a close look at the BasicProgressBarUI class in the Swing source code.
    (The source code can be found in your <java-home> directory in src.zip)
    You can extend this class, and override the paintDeterminate(Graphics, JComponent) method to alter the drawing of the progress bar. This may do what you need. Eg.
    public class MyProgressBarUI extends BasicProgressBarUI
      protected void paintDeterminate(Graphics g, JComponent c)
        // your painting code here
    Also, then set this into your JProgressBar component like so:
    JProgressBar pb = new JProgressBar( );
    pb.setUI( new MyProgressBarUI( ) );
    - Paul

  • CFGrid - 1st  maxlength for a cfgridcolumn/ 2nd - YES entered displayed as True?

    I have an cfgridrow that should only allow 3 digits, is there a way to set the maxlength on a cfgridcolumn? If so, how is this done?
    2nd:
    I have a column for notes:
    <CFGRIDCOLUMN NAME="TeamNotes" SELECT="YES" HEADER="Team Notes" TYPE="STRING_NOCASE">
    if Yes is typed in and saved when the screen is refreshed it is displayed as TRUE (but in the database is saved as Yes) happens also with No (displayed as False) is there a way to make it displayed exactly what is in the database?

    Thanks, Shawn. 
    All that being said, the best solution would be to not create a DVD. This sort of project would be much easier, and give you better results if you did this in Flash. The only reason I could see to use a DVD would be if the testers only had access to a DVD player and not a computer.
    That was exactly my sugestion as well.  But the client is quite insistent on creating the project as a DVD - yes the DVD Player uption is a requirement.
    I have created DVD with several thousand links... very daunting, but turned out well and the customer was very happy.
    I reviewed the DVDSP manual to make sure what the customer wanted was not covered, but I wanted to make sure.
    What I have suggested is that when I student gets an answer wrong that an option is given to review the relavent section.  Since there will be less that 100 question, it would not be a big deal to created an appropriate final score bases on a GPRM value.
    Thank you very much for the rreply.  It is greatly apprecaited.

  • Dateformat in cfgridcolumn using mask?

    I tried this...not working...How to format date in
    cfgridcolumn?.
    cfgridcolumn name="s_date" header="s_date" display="Yes"
    headerbold="Yes" headeritalic="No" width="100" mask="MM/DD/YYYY"
    please help.

    you can always format t in your query the cfgrid is based
    on...
    Azadi Saryev
    Sabai-dee.com
    http://www.sabai-dee.com/

  • Pass cfgridcolumn calculated value

    I have this query:
    select bcastreq.bcast_id, bcastreq.affiliate_id,
    bcastreq.subject, bcastreq.reqtimestamp, affiliate.affiliatename,
    bcastreq.affiliatetype_id, count(editbcastreq.bcast_id) as
    editcount, editbcastreq.affiliatetype_id
    from bcastreq
    left join editbcastreq
    on bcastreq.bcast_id = editbcastreq.bcast_id
    left join affiliate
    on bcastreq.affiliate_id = affiliate.affiliate_id
    group by bcastreq.bcast_id
    And it populates this grid:
    <cfgrid name="requestgrid" query="getOriginalreq"
    format="html" autowidth="yes" selectonload="false" striperows="yes"
    gridlines="yes" href="editreq.cfm" hrefkey="bcast_id" >
    <cfgridcolumn name="bcast_id" header="Broadcast ID"
    display="yes" >
    <cfgridcolumn name="affiliatetype_id" header="Affiliate
    Type ID" display="yes">
    <cfgridcolumn name="affiliate_id" header="Affiliate ID"
    display="yes">
    <cfgridcolumn name="affiliatename" header="Affiliate Name"
    >
    <cfgridcolumn name="subject" header="Subject" >
    <cfgridcolumn name="editcount" header="No. Edits">
    <cfgridcolumn name="reqtimestamp" header="Submit
    Date/Time" >
    How do you pass a value from a column? Specifically, when the
    user clicks a record I need/want to pass the calculated column
    <cfgridcolumn name="editcount" header="No. Edits"> on to the
    next page. The normal
    <cfoutput>#form.editcount#</cfoutput> does not seem to
    be working.

    So I figured it out if anyone's interested here's my updated code ...
    (I changed the "h ref"s to "submit"s so it has buttons instead of text, but it works either way)
    (can't seem to colorize the text as I did in the original post, changes are in bold)
    if (isset($_GET['add_quant'])) {
    $quantity = $_POST['input_quantity'];
    $_SESSION['cart_'.(int)$_GET['add_quant']]+= $quantity;
    header('Location: '.$page);
    exit();
    function products() {
    echo '<div class="show_bg"><h2>Current Tickets available online</h2>';
    $get = mysql_query("SELECT * FROM tickets WHERE soldout = 'no' && price > 0 ORDER BY date ASC");
    if (mysql_num_rows($get)==0){
      echo "There are no Tickets currently for sale";
    else {
    while ($get_row = mysql_fetch_assoc($get)) {
       echo '<div class="show_name"><p>'.$get_row['name'].'</p></div><p>'.$date = date('F jS Y', strtotime($get_row['date'])).'<br />'.'$'.number_format($get_row['price'], 2).' per ticket</p>'.'<p>Add tickets:</p>
       <form class="inline_form" action="cart.php?add_quant='.$get_row['id'].'" method="post" />
       <input type="number" name="input_quantity"  value="'.$get_row['input_quantity'].'" size="2" />
       <input type="submit" value="Add Quantity" /></form>
       <hr />';
    echo '</div>';

  • CFGRIDCOLUMN HTML textcolor and headertextcolor NOT working

    Yet another HTML CFGRID "bug"? Does anyone have a working
    example of CFGRIDCOLUMN with headertextcolor and/or textcolor
    working?
    I've tried this on 3 different CF environments with no
    success. I can actually see the style tag with the color defined
    but nothing works. I tried using both "Blue" and "##0000FF". Even
    more bizarre, if the textcolor is set and the column has an
    HREF="xxx" then the underline is set to the color but NOT the
    text.

    Did you find the answer to this?  I need to set the cell's background and text/font color.

  • Default values within cfgridcolumn

    Hi,
    I was wondering whether or not there is a way to pass a
    default value into a <cfgridcolumn> whenever a new row is
    inserted. I am using <cfgridupdate> and I need to pass a
    foreign key ID based on the usersID alongside any data they enter
    into the record. Any help or advice would be appreciated.

    Just in case anyone else is having this problem, I have
    managed to solve it.
    Not sure if it was the "Correct" way to solve it but it
    works.
    I needed to pass a foreign key value (based on the users
    login) as a default value into each new record in the DataGrid. The
    method i used was to create a hidden text box on the page, i passed
    the variable into the text box and then used the following code to
    bind it to the record.
    onchange="gridMainBusinessObjectives.dataProvider.editField(gridMainBusinessObjectives.sel ectedIndex,'companyID',hidCompanyID.text);"
    The above code is part of the grids onChange event
    "hidCompanyID" is the name of the hidden text box containing
    my foreign key
    I hope this can be of some use to anyone who is having the
    same problem I was having.

  • Cfgridcolumn problem

    I have an editable cfgrid.
    The database updates are made using a bind in the onChange attribute.
    One of the editable columns uses a dropdown list, specifically the COACH_NAME column.
    The database is appropriately updated when the user changes the "coach" selection.
    However what is displayed after the onChange event, is the new COACH_ID, not the desired name.
    I don't understand...
                <cfform>
                    <cfgrid name="records" format="html" selectmode="edit"
                        bind="cfc:#application.cfcpath#cfcs.coach.getRecords({cfgridpage},{cfgridpagesize},{cfgri dsortcolumn},{cfgridsortdirection},{season},{ageGroup},{bracket})"
                            onChange="cfc:#application.cfcpath#cfcs.coach.updateGridRecord({cfgridaction},{cfgridrow} ,{cfgridchanged})"
                            bindonload="no"
                            >
                            <cfgridcolumn name = "RECORDS_ID" display = "No">
                            <cfgridcolumn name = "PLACE" header = "Place" width="80" select="no">
                               <cfgridcolumn name = "TEAM_NAME" header = "Team" width="100">
                            <cfgridcolumn name = "POINTS" header = "Points" width="100">
                            <cfgridcolumn name = "COACH_NAME" header = "Coach" Select="Yes"
                            textcolor="blue" bold="Yes" width="130" values="#valueList(qGetCoaches.COACH_ID)#" valuesdisplay="#valueList(qGetCoaches.COACH_NAME)#">
                    </cfgrid>
                </cfform>
    What's wrong with this?

    You may want to consider doing this on the database side.  You could add a column called Sort, copy the data as upper
    case, and sort on that column instead.  Just an idea.
    Good luck

  • CF8 HTML CFGRIDCOLUMN target broken

    In CF7 & CF8 the applet version of CFGRID works properly
    when specifying target="iframename" in a CFGRIDCOLUMN. It seems to
    NOT work when using the HTML version. The code I am using is a
    single .cfm file with 3 IFRAMEs. The 1st IFRAME contains a CFTREE.
    The person clicks a node and the 2nd IFRAME loads a CFGRID with a
    list of documents. Clicking on the document loads it in the 3rd
    IFRAME. This works fine if the CFGRID is APPLET. If it is HTML the
    message "Grid HREF target not found: iframe3name [Enable
    debugging.....]"
    Any ideas? Confirmations? How do I report this to Adobe as a
    bug?

    Well with a little more research the problem is that the
    target name is being lowercased by CF. My IFRAME name was
    imapMessage and the error message was saying the target name not
    found was imapmessage. Once I realized that and changed my IFRAME
    id and name to imapmessage vs imapMessage it worked. SO I believe
    this is a CF bug.
    Anyone know how/where to report this?

  • HTML CFGRIDCOLUMN values showing up for valuesdisplay issue

    I'm using cfgrid type=html.  I am creating a dropdown box in the cfgrid, however in the dropdown box it is showing the Values, instead of the ValueDisplay in the dropdown box.
    <cfgrid name = "SecondGrid"
            height="200" width="700"
            font="arial" fontsize="12"
            query = "getsecurity"
            SORT="Yes"
            selectmode="edit"
            format="html"
            insert="yes"
            delete = "#deletevalue#"
            >
    <CFGRIDCOLUMN NAME="userrole" HEADER="User Role"
            HEADERALIGN="LEFT" DATAALIGN="LEFT"
            BOLD="Yes" ITALIC="No"
            SELECT="Yes" DISPLAY="Yes"
            HEADERBOLD="No" HEADERITALIC="Yes"
            VALUES = "teacher,adminassist"
            VALUESdisplay = "Teacher, Administrator"  valuesDelimiter=",">
    </cfgrid>
    Thanks for your help!
    BCo

    Coladan,
    This is, most likely, a rounding problem.  The sum of the numbers is probably a VERY, VERY, VERY small, negative number.  if you use the round function this should resolve.
    instead of using:
    =SUM(P4:P5)
    try:
    =round(SUM(P4:P5), 2)
    Where "2" is the number of digits to the right of the decimal

Maybe you are looking for

  • "Cannot send message using the server....."

    Hi all, Considering the nature of the problem I am about to relate I would have to say at the outset that I would be very very surprised if other people have not come across this problem, so here goes... We have around 60 users of Apple Mail from bot

  • Update rules Activation Problem

    Hi, Iam getting the error while transporting the update rules to production,saying error mesage,   Start of the after-import method for object type R3TR UPDR (Activation Mode)   Update rules 4AR6MO7P6M428KB2RPA65E9EX read in version M   Error when ac

  • My Macbook Pro will not start up

    I've had my Macbook Pro for a little over a year and have never had any problems with it, until last night. I still have Tiger, and I loaded a Quicktime update and started to reboot, but every time I tried to reboot, it would sit at the startup scree

  • How to export all edited photos in a project

    Once I finish editing photos in a project I often wish to export all of those photos, in their fnal edited form, to a folder which I then burn to a CD and give to someone.  I have been using File-Export-Versions thinking that this would do the trick.

  • Using older OS with iPad

    I am thinking of buying an iPad. I see that the specs require OS 10.5 or above. I have OS 10.4.11. What problems will I encounter using an iPad with my computer?