|
-
Sep 9th, 2005, 06:19 AM
#1
Thread Starter
Junior Member
too long string
i am getting "too long string" error from the following code from line with exclamation mark. In this textbox i am typing the text which is about 3 to 5 lines. how can i get rid of this error
Private Sub cmdDoc_Click()
Dim wordapp As Word.Application
Dim thisdoc As Document
Dim thisrange As Range
Set wordapp = CreateObject("word.application")
If wordapp Is Nothing Then
MsgBox "could notstart word"
End If
wordapp.Documents.Open ("C:\documents and settings\administrator\application data\microsoft\templates\C-00.dot")
Set thisdoc = wordapp.ActiveDocument
thisdoc.FormFields(1).Result = txtName.Text
thisdoc.FormFields(2).Result = txtFNo.Text
thisdoc.FormFields(3).Result = txtRef.Text
thisdoc.FormFields(4).Result = txtNo.Text
thisdoc.FormFields(5).Result = txtSite.Text
thisdoc.FormFields(6).Result = txtMic.Text ??????
thisdoc.FormFields(7).Result = txtDiag.Text
please help me
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|