Search code examples
export-to-excelibm-doors

Export DOORS attribute font color to Excel font color


I've seen the discussion in https://www.ibm.com/developerworks/community/forums/html/topic?id=7981c520-ee1b-4a5f-b1f7-510172d2a3bd&ps=25 and have a copy of the GalacticSolutions Excel export script. That script takes the color of the font in a module cell and maps it to the Excel cell-fill color. What isn't clear to me is how to take that same source color and map it instead to the Excel cell's text color.
My source attribute is an enumeration with the assigned colors setting the font color as in this picture . Perhaps the simplest answer that would help me is if someone familiar with the GalacticSolutions script , , could identify the code which passes the color to the cell fill-color and provide the equivalent command to handle the font color. thanks Carl


Solution

  • I received an answer on an IBM forum and am copying it here.

    dowhich = "Interior"  //to shade the cell
    dowhich = "Font" //to color the font
    
    void excelSetRangeColorOLE( OleAutoObj objExcelRange, int iRGBValue ) { OleAutoObj objExcelInterior = null oleResult( oleGet( objExcelRange, dowhich, objExcelInterior ) ) oleResult( olePut( objExcelInterior, "Color", iRGBValue ) ) }