回覆列表
  • 1 # 使用者1220686403821

    在datagridview中rowpostpaint事件中如下寫法:

    privatevoiddatagridviewapplydetail_rowpostpaint(objectsender,datagridviewrowpostpainteventargse)

    {

    rectanglerectangle=newrectangle(e.rowbounds.location.x,e.rowbounds.location.y,datagridviewapplydetail.rowheaderswidth-4,e.rowbounds.height);

    textrenderer.drawtext(e.graphics,(e.rowindex+1).tostring(),datagridviewapplydetail.rowheadersdefaultcellstyle.font,rectangle,

    datagridviewapplydetail.rowheadersdefaultcellstyle.forecolor,

    textformatflags.verticalcenter|textformatflags.right);

    }

  • 中秋節和大豐收的關聯?
  • 秋風清求全詩?