STM32F0 (master) writing multiple bytes by I2C to MCP4728 (slave) using StdPeriphLibrary
OK i managed with this problem - checking of TCR flag in loop was mistake. The working code is below:

void I2C_HW_tx(uint8_t i2cAddr, uint8_t *dataTx, uint8_t length,
        uint8_t stopOrNotWhenSent) {

if (stopOrNotWhenSent == STOP_WHEN_SENT) {
    I2C_TransferHandling(I2C_PERIPH, i2cAddr, length,
    I2C_AutoEnd_Mode,
    I2C_Generate_Start_Write);
    //PRINTF("\nI2C_tx - 1\n");
    while (I2C_GetFlagStatus(I2C_PERIPH, I2C_FLAG_TXIS) == RESET)
        ;
    //PRINTF("\nI2C_tx - 2\n");
    for (uint8_t i = 0; i &lt; length; i++) {
        while (I2C_GetFlagStatus(I2C_PERIPH, I2C_FLAG_TXE) == RESET)
            ;
        I2C_SendData(I2C_PERIPH, *(dataTx + i));
        //PRINTF("\nI2C_tx - 3\n");
    }
    while (I2C_GetFlagStatus(I2C_PERIPH, I2C_FLAG_STOPF) == RESET)
        ;
    I2C_ClearFlag(I2C_PERIPH, I2C_FLAG_STOPF);
} else {
    I2C_TransferHandling(I2C_PERIPH, i2cAddr, length, I2C_SoftEnd_Mode,
    I2C_Generate_Start_Write);
    //PRINTF("\nI2C_tx - 1\n");
    while (I2C_GetFlagStatus(I2C_PERIPH, I2C_FLAG_TXIS) == RESET)
        ;
    //PRINTF("\nI2C_tx - 2\n");
    for (uint8_t i = 0; i &lt; length; i++) {
        while (I2C_GetFlagStatus(I2C_PERIPH, I2C_FLAG_TXE) == RESET)
            ;
        I2C_SendData(I2C_PERIPH, *(dataTx + i));
        //PRINTF("\nI2C_tx - 3\n");
    }
    while (I2C_GetFlagStatus(I2C_PERIPH, I2C_FLAG_TC) == RESET)
        ;
    //PRINTF("\nI2C_tx - 4\n");
}
//PRINTF("\nI2C_tx - 5\n");


}

The one thing that I don't know how to do is WriteI2CAddress to MCP4728 slave device (http://ww1.microchip.com/downloads/en/DeviceDoc/22187E.pdf - page 42). LDAC line should become low from high state during 8th bit of command. Do you know how to do it using hardware I2C in STM32?