محمد طاهر عرفه قام بنشر يونيو 8, 2003 قام بنشر يونيو 8, 2003 المثال به عدد 2 كود الأول يقوم باخراج محتويات الثلاث خلايا الملونة بعد دمجها الي ملف نص و فتحهد و الثاني يقوم باخراج الخلايا فى سطور مستقلة Sub Macro2() a = Cells(3, 2) & "," & Cells(3, 3) & "," & Cells(3, 4) Dim Filename As String Filename = "c:\testfile.txt" Open Filename For Output As #1 Print #1, a Close #1 Dim x x = Shell("notepad.exe c:\testfile.txt", 1) End Sub Sub Macro3() a1 = Cells(3, 2) a2 = Cells(3, 3) a3 = Cells(3, 4) Dim Filename As String Filename = "c:\testfile.txt" Open Filename For Output As #1 Print #1, a1 Print #1, a2 Print #1, a3 Close #1 Dim x x = Shell("notepad.exe c:\testfile.txt", 1) End Sub و يلاحظ وجود طريقة أخري للكتابة فى ملف نص Sub anotherway() Dim fs, S, A Set fs = CreateObject("Scripting.FileSystemObject") Set A = fs.CreateTextFile("c:\" & "temp.txt", True) A.writeline "Pivots per Sheet - in File named : " & ActiveWorkbook.FullName & " : " A.writeline A.writeline "*********** Prepared By Mohamed Taher *****************" A.writeline A.Close Dim x x = Shell("notepad.exe c:\temp.txt", 1) End Sub WriteTotext.rar
omer48 قام بنشر مايو 8, 2019 قام بنشر مايو 8, 2019 مرحبا أستاذي أريد كيفية تحويل ملف اكسل الى نص لكن كما في الصورة التي ابعثها لك
وجيه شرف الدين قام بنشر مايو 8, 2019 قام بنشر مايو 8, 2019 بارك الله فيكم وجعله الله فى ميزان حسناتكم
boussaid قام بنشر مايو 9, 2019 قام بنشر مايو 9, 2019 أخ @omer48 يبدو انو هذا ملف العملية التضامنية لرمضان هل حللت مشكلتك أم ما زلت بحاجة لعملية التحويل ؟
الردود الموصى بها
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.