📌  相关文章
📜  como acessar um elementRef de um componente - TypeScript 代码示例

📅  最后修改于: 2022-03-11 14:48:29.396000             🧑  作者: Mango

代码示例1
@ViewChild('FileDialog') FileDialog: ElementRef;

 open_dialog() {
        const e: HTMLElement = this.FileDialog.nativeElement;
        e.click();
    }

//no html criei a variavel FileDialog tbm