Python from tkinter import messagebox

Python from tkinter import messagebox
import uuid
import pandas as pd
from datetime import datetime
from tkinter import messageboxdata_list=[]
arr=range(1,1000001)
for a in arr:data_list.append({"Id":a,"Name":f'Name_{a}',"Author":F"Author_{a}","ISBN":f'ISBN_{a}_{uuid.uuid4().hex}',"FName":f'FName_{a}',"MName":f"MName_{a}","LName":f"LName_{a}","Title":f'Title_{a}',"FTitle":f"FTitle_{a}","MTitle":f"MTitle_{a}","LTitle":f"LTitle_{a}","Topic":f'Topic_{a}',"FTopic":f"FTopic_{a}","MTopic":f'MTopic_{a}',"LTopic":f'LTopic_{a}', })csv_file=f'CSV_{datetime.now().strftime("%Y%m%d%H%M%S%f")}.csv'
df=pd.DataFrame(data_list)
df.to_csv(csv_file,index=False,encoding='utf-8-sig')
msg=f'{datetime.now()} save data in {csv_file}'
print(msg)
messagebox.showinfo("Info",msg)
messagebox.showerror("Error",msg)
messagebox.showwarning("Warning",msg)

 

 

 

image

 

 

 

 

 

 

 

image

 

 

 

image