林回收視圖試圖在對話,但對話框不顯示任何添加回收看法......我增加了關於回收視圖卡和要顯示在對話框如何添加在對話框
android.support.v7.app.AlertDialog.Builder dialog = new android.support.v7.app.AlertDialog.Builder(getContext());
LayoutInflater inflater = (LayoutInflater) getContext().getSystemService(Context.LAYOUT_INFLATER_SERVICE);
View dialogView = inflater.inflate(R.layout.last_transaction_report, null);
recyclerView = (RecyclerView) dialogView.findViewById(R.id.transactio_rep_recyclerView);
dialog.setView(dialogView);
AlertDialog alertDialog = dialog.create();
// alertDialog.setContentView(dialogView);
alertDialog.show();
adapter = new TransactionReportCardAdapter(listTransactionDetails, this);
recyclerView.setAdapter(adapter);
setAdapter(不能應用於LastTransactionsAdapter類 –
@suraj什麼是LastTransactionsAdapter類? –
在textview上設置數據,並將這些textview添加到cardview上 –