Workbooks.Open oddity
Dim n As Range
Dim c As Range
'
Workbooks.Open Filename:="PAGE1.xml"
'
myOpenXML
prepare_open_xml ' delete all columns that we
don't need & format nicely
saveasXLS
Set n = Range("A3:F" & LastCell(ActiveSheet).Row)
' Atempt with PasteSpecial and multiplication with 1 : doesn't
work
' Range("A1").FormulaR1C1 = "1"
' Range("A1").Copy
' n.PasteSpecial Paste:=xlPasteAll, Operation:=xlMultiply,
SkipBlanks:=True, Transpose:=False
' Application.CutCopyMode = False
' Range("F3").Select
' Atempt with replace and a new comma : doesn't work
' n.Replace What:=",", Replacement:=",", LookAt:=xlPart
' attempt with type conversion of every single cell : at least this
one works!
For Each c In n
If TypeName(c.Value) = "String" Then
If InStr(1, c.Value, ",") Then
c.Value = CDbl(c.Value)
Else
c.Value = CInt(c.Value)
End If
End If
Next c
|