Table with links

How can I add a link into the table rows?

I have a class which extends Grid

        addColumn(PatientInfo::getProgram)
                .setCaption("Program"));
        addColumn(PatientInfo::getId)
                .setCaption("ID"));

How can I add that Program column will contain a link to other website?

You could use an HtmlRenderer:

        tbRezepte.addColumn((source) -> {
            return MessageFormat.format(VaadinIcons.EXTERNAL_LINK.getHtml() + "\n"
                    + "    <a href=\"https://www.yyy.org/{0}\" target=\"_blank\">\n"
                    + "       {0}\n"
                    + "    </a>\n"
                    + "", source.getTitle());
        }, new HtmlRenderer()).setCaption("Caption").setExpandRatio(70);

Alternatively, you can use addComponentColumn to add a Link component.

-Olli