
'********************************************* 'Inserimento dati in una tabella prestabilita' '********************************************* Private Sub CommandButton1_Click() Dim RowCount As Long Dim ctl As Control Dim new_can As String 'Inserimento in tabella RowCount = Worksheets("Computo").Range("B" & Rows.Count).End(xlUp).Row With Worksheets("Computo").Range("B6") .Offset(RowCount, 7).Value = TextBox1.Value '**************************************************************** 'Codice da utilizzare se in qualce textbox ci sono valori in euro ”Formattazione” '***************************************************************** On Error Resume Next .Offset(RowCount, 8) = CDbl(Replace(TextBox4, "€ ", "")) On Error GoTo 0 End With new_can = ComboBox1.Value 'CaricaDati End Sub |
Private Sub CommandButton1_Click()
Dim RowCount As Long
Dim ctl As Control
Dim new_can As String
'Inserimento in tabella
RowCount = Worksheets("Computo").Range("B" &_ Rows.Count).End(xlUp).Row
With Worksheets("Computo").Range("B6")
.offset(Discount,0).value=cdate(data.caption)
.Offset(RowCount,7).Value = TextBox1.Value
'**************************************************************
'Codice da utilizzare se in qualce textbox ci sono valori in euro ”Formattazione” '**************************************************************
On Error Resume Next
.Offset(RowCount, 8) = CDbl(Replace(TextBox4, "€ ", ""))
On Error GoTo 0
End With
new_can = ComboBox1.Value
'CaricaDat
i End Sub |
.offset(Discount,7)=chr(10) (replace(textbox1,"","")) |
.Offset(RowsCount,8)=Replace(Chr(10),"textbox1.text ," ") |
.Offset(RowsCount,8)=Replace(textbox1.text,Chr(10)," ") |
