簡體   English   中英

#問題Flutter 1:如何在flutter中實現這個?

[英]#Question Flutter 1: How can i achieve this in flutter?

我想將一個 listDevice 從一個屏幕傳遞到另一個屏幕,但我在下一個屏幕上沒有得到任何數據? 我遇到了什么語法錯誤?
屏幕 1:數據傳輸

Navigator.pushNamed(context, 'deviceInformation', arguments: listDevice);

第二屏:接收數據

final arguments = ModalRoute.of(context)!.settings.arguments as Data;

你能試試 Navigator.pushNamed(context, '/deviceInformation' , arguments: listDevice);

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM