Code:
Dim sFile As String, dFile As String On Error GoTo Salah If Dir(sFile) <> "" Then Open (App.Path & "\proposal.rtf") For Output As #1 Open (App.Path & "\proposal_output.rtf") For Output As #2 Do While Not EOF(1) Line Input #1, tmDat$ sReplace = Replace(sReplace, "<<nama>>", nama.Text) sReplace = Replace(sReplace$, "<<nim>>", nim.Text) Print #2, sReplace$ DoEvents() Loop Close() End If ShellExecute(hWnd, "open", dFile, "", App.Path, 1) Exit Sub Salah: MsgBox(Err.Description, vbInformation, "Terjadi Kesalahan")
I HAVE PROBLEM IN APP.PATH
Comment