Ejemplo n.º 1
0
def func_replace():
    if (inputtext.get() == ""):
        easygui.exceptionbox(msg="enter file name with its path",
                             title="WARNING")
        return

    e = easygui.enterbox(msg="enter value to be replaced",
                         title="replace text",
                         default="")
    e2 = easygui.enterbox(msg="replace previous value with",
                          title="replace with text",
                          default="")
    if (easygui.boolbox(msg="Are you  sure", title="confirm")):
        FileManupulation(inputtext.get()).replace_all(e, e2)
Ejemplo n.º 2
0
def func_append_content():
    e = easygui.codebox(msg='enter data to be appended',
                        title="append content")
    if (e != ""):
        FileManupulation(inputtext.get()).append_content(e)
Ejemplo n.º 3
0
def func_append_file():
    FileManupulation(inputtext.get()).append_file(inputtext1.get())
Ejemplo n.º 4
0
def func_create():
    FileManupulation(inputtext.get()).create_file(inputtext.get())
Ejemplo n.º 5
0
def func_delete():
    FileManupulation(inputtext.get()).delete_file(inputtext.get())
Ejemplo n.º 6
0
def func_show():
    root2 = Toplevel()
    val = inputtext.get()
    con = FileManupulation(val).show_file() + ""
    Label(root2, text=con, width=100, height=5, bg="white").pack()
    root2.mainloop()
Ejemplo n.º 7
0
def func_delete_data():
    if (easygui.boolbox(msg="Are you  sure to delete content of file",
                        title="confirm")):
        FileManupulation(inputtext.get()).delete_content()