Skip to content

quickfixgo quickfix.Message.Body.Set not work #702

@dablelv

Description

@dablelv

I want to change the Account field by calling quickfix.Message.Body.Set, but the quickfix.Message doesn't change.

Why? Is this a bug or am I using it wrong?

var RawFixMsg *quickfix.Message

// init RawFixMsg
// ...

var accid uint64 = 123456
RawFixMsg.Body.Set(field.NewAccount(strconv.FormatUint(accid, 10)))

When i to print the fix message content by follow codes,found the Account field not changed.

fmt.Println(ReadableFix(RawFixMsg.String()))

func ReadableFix(s string) string {
	soh := string(rune(1))
	return strings.Replace(s, soh, "|", -1)
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions