Qt World Summit: Submit your Presentation

[SOLVED] save value of qint16 to qint8

  • i have a lineedit.
    @qint16 moduliINT
    in moduliINT I have value converted to decimal
    Now, I have a structure:
    @typedef struct {
    unsigned char moduli;
    } _PROTEZ;@

    @_PROTEZ prot@

    I want to save the value of moduliINT in port.moduli.

    but moduliINT is 2 bytes, while prot.moduli is 1 byte.


    I did so but it does not work.

    how can I do?

Log in to reply