27-10-15, 09:20 PM
(آخر تعديل لهذه المشاركة : 27-10-15, 10:52 PM {2} بواسطة hamada salah90.)
اخواني الأعزاء بعد التحية
أريد كود لإستيراد البيانات الموجودة في جدول من الوورد office word 2003
وعرض هذه البيانات في مربعات نص في الفيجول بيسك
وهذا مثال مرفق للتعديل عليه

ملاحظة هامة !!
أنا لدي هذا الكود لإستيراد البيانات من الفيجول وعرضها في الوورد
أريد كود مشابه لنفس هذا الكود لو سمحتم
كود :
Static MonWd As Word.Application
Static wmonwd As Word.Document
Set MonWd = New Word.Application
MonWd.Visible = True
Set wmonwd = MonWd.Documents.Open(App.Path & "\Tests\" & (ComboTests.Text) & ".doc")
With wmonwd
'======--------------------=============------------==============
'-----------------main table----------------
.FormFields("W_code").Range = txtCode.Text
.FormFields("W_name").Range = txtname.Text
.FormFields("W_doc").Range = txtDoc.Text
.FormFields("W_age").Range = txtage.Text + ", " + txtGender.Text
.FormFields("W_samD").Range = txtSamDate.Text
.FormFields("W_resD").Range = txtResDate.Text
'-----------------Result table----------------
.FormFields("W_txtT17").Range = "Dr. " + lblUsername.Caption
.FormFields("W_txtT1").Range = txtT1.Text
.FormFields("W_txtT2").Range = txtT2.Text
.FormFields("W_txtT3").Range = txtT3.Text
.FormFields("W_txtT4").Range = txtT4.Text
.FormFields("W_txtT5").Range = txtT5.Text
.FormFields("W_txtT6").Range = txtT6.Text
.FormFields("W_txtT7").Range = txtT7.Text
.FormFields("W_txtT8").Range = txtT8.Text
.FormFields("W_txtT9").Range = txtT9.Text
.FormFields("W_txtT10").Range = txtT10.Text
.FormFields("W_txtT11").Range = txtT11.Text
.FormFields("W_txtT12").Range = txtT12.Text
.FormFields("W_txtT13").Range = txtT13.Text
.FormFields("W_txtT14").Range = txtT14.Text
.FormFields("W_txtT15").Range = txtT15.Text
.FormFields("W_txtT24").Range = txtT24.Text
.SaveAs Filename:=App.Path & "\Tests\" & Trim$(ComboTests.Text) & Trim$(txtCode.Text) & ".doc"
'======--------------------=============------------==============
End With
Set MonWd = Nothing
Set wmonwd = Nothing
"" بارك الله لكل من استفاد و أفاد بعلمه ""
hamada salah
