D
Darren Hill
I have a routine below,
I have a form in which data is entered. I then cycle through the
textboxes on the form, and paste the contents to a sheet.
It's all working fine, except that at one point, the contents of several
text boxes are pasted together, and pasted into a single cell. This can
often create a formula over 250 characters in length, in the following
format:
"=" & "some text" & D72 & "lots of text" & D74.
For these results, the routine below errors out at the problem line.
Is there a work around that would allow me to paste a simple-but-long
formula of over 256 characters?
Thanks.
Sub UpdateCells(sOnForm As String, ws As Worksheet, iSet As Integer,
sSetLabel As String)
Dim rgToEdit As Range
'the following line uses the parameters to find where the
' current contents of sOnForm should be pasted.
Set rgToEdit = FindSetRange(ws, iSet, sSetLabel)
rgToEdit.Formula = sOnForm '<<< here's the problem.
End Sub
Darren
I have a form in which data is entered. I then cycle through the
textboxes on the form, and paste the contents to a sheet.
It's all working fine, except that at one point, the contents of several
text boxes are pasted together, and pasted into a single cell. This can
often create a formula over 250 characters in length, in the following
format:
"=" & "some text" & D72 & "lots of text" & D74.
For these results, the routine below errors out at the problem line.
Is there a work around that would allow me to paste a simple-but-long
formula of over 256 characters?
Thanks.
Sub UpdateCells(sOnForm As String, ws As Worksheet, iSet As Integer,
sSetLabel As String)
Dim rgToEdit As Range
'the following line uses the parameters to find where the
' current contents of sOnForm should be pasted.
Set rgToEdit = FindSetRange(ws, iSet, sSetLabel)
rgToEdit.Formula = sOnForm '<<< here's the problem.
End Sub
Darren