PEATDB/Tables.py
def fill_across(self, collist, rowlist):
        """Fill across a row, or multiple rows"""
        model = self.model
        #row = self.currentrow
        #absrow  = self.get_AbsoluteRow(collist[0])
        frstcol = collist[0]
        collist.remove(frstcol)

        for row in rowlist:
            absr = self.get_AbsoluteRow(row)
            val = self.model.getCellRecord(absr, frstcol)
            f=val     #formula to copy
            i=1
            for c in collist:
                if Formula.isFormula(f):
                    newval = model.copyFormula(f, absr, c, offset=i, dim='x')
                    model.setFormulaAt(newval, absr, c)
                else:
                    model.setValueAt(val, absr, c)
                i+=1
        self.redrawTable()
        return
Fill across a row, or multiple rows
Fill across a row, or multiple rows
Fill across a row or multiple rows
def fill_across(self, collist, rowlist):
        model = self.model
        frstcol = collist[0]
        collist.remove(frstcol)
        for row in rowlist:
            absr = self.get_AbsoluteRow(row)
            val = self.model.getCellRecord(absr, frstcol)
            f=val     
            i=1
            for c in collist:
                if Formula.isFormula(f):
                    newval = model.copyFormula(f, absr, c, offset=i, dim='x')
                    model.setFormulaAt(newval, absr, c)
                else:
                    model.setValueAt(val, absr, c)
                i+=1
        self.redrawTable()
        return
def fill_across ( self , collist , rowlist ) : model = self . model frstcol = collist [ 0 ] collist . remove ( frstcol ) for row in rowlist : absr = self . get_AbsoluteRow ( row ) val = self . model . getCellRecord ( absr , frstcol ) f = val i = 1 for c in collist : if Formula . isFormula ( f ) : newval = model . copyFormula ( f , absr , c , offset = i , dim = 'x' ) model . setFormulaAt ( newval , absr , c ) else : model . setValueAt ( val , absr , c ) i += 1 self . redrawTable ( ) return
Fill across a row, or multiple rows
Fill across a row or multiple rows
"""Fill across a row, or multiple rows""" #row = self.currentrow #absrow  = self.get_AbsoluteRow(collist[0]) #formula to copy
self
collist
rowlist