Public Function FUN_IN_DOCS(MyCol, MyRow, MyText, str_Aligment)
' вставка в ячейку
On Error GoTo FUN_IN_DOCS_Error
'----------------------------------------------------------------------------------
Set OOO_Range = OOO_Sheet.getCellByPosition(MyCol, MyRow)
OOO_Range.ParaAdjust = str_Aligment '3 ' слева2 справа1 центр3
Select Case TypeName(MyText)
Case "String"
If Left(MyText, 1) = "=" Then
OOO_Range.SetFormula MyText
Else
OOO_Range.setString MyText
End If
Case "Double", "Integer", "Long", "Currency", "Single"
OOO_Range.SetValue MyText
End Select
'----------------------------------------------------------------------------------
On Error GoTo 0
Exit Function
FUN_IN_DOCS_Error:
Call FUN_IN_TXT(FUN_Patch_File(App.Path, "Error.txt"), "Error " & Err.Number & " (" & Err.Description & ") in procedure FUN_IN_DOCS of Module OOO_MOD")
End Function
'
|