Hi all,
I know there are people like me (noobs) out there in search of crumbs.
So, I have made or found one piece of code, and my need evolved ... created or found another piece and so on ...
Before I give you my example I would like to invite you all to share your ideas, even if they might not work for me, they might still be very helpful for someone else.
and here are my codes that do NOT work as they do separately if I put them together (tried with 'call macro_name', writing into a single macro the whole thing, even telling excel to have a break between the two) but still no luck.
1st set of actions that I want:
and the second one:
thank you in advance for your thoughts, time and ideas !
I know there are people like me (noobs) out there in search of crumbs.
So, I have made or found one piece of code, and my need evolved ... created or found another piece and so on ...
Before I give you my example I would like to invite you all to share your ideas, even if they might not work for me, they might still be very helpful for someone else.
and here are my codes that do NOT work as they do separately if I put them together (tried with 'call macro_name', writing into a single macro the whole thing, even telling excel to have a break between the two) but still no luck.
1st set of actions that I want:
Code:
Sub conc_trans()
Dim rRange As Range
On Error Resume Next
Application.DisplayAlerts = False
Set rRange = Application.InputBox(Prompt:= _
"Selecteaza celule sau scrie aici", _
Title:="SPECIFY RANGE", Type:=8)
On Error GoTo 0
Application.DisplayAlerts = True
If rRange Is Nothing Then
Exit Sub
Else
ActiveWorkbook.ActiveSheet.Sort.SortFields.Clear
ActiveWorkbook.ActiveSheet.Sort.SortFields.Add Key:=rRange, _
SortOn:=xlSortOnValues, order:=xlAscending, DataOption:=xlSortNormal
With ActiveWorkbook.ActiveSheet.Sort
.SetRange rRange.CurrentRegion
.HEADER = xlGuess
.MatchCase = False
.Orientation = xlTopToBottom
.SortMethod = xlPinYin
.Apply
End With
ActiveWorkbook.Names.Add Name:="trans", RefersToR1C1:=rRange
ActiveWorkbook.Names("trans").Comment = ""
Selection.FormulaR1C1 = "=CONCATENATE(TRANSPOSE(trans&"",""))"
End If
SendKeys "{F2}"
SendKeys "{F9}"
SendKeys "^~"
End Sub
and the second one:
Code:
Sub CLR_selection()
With Selection
.Replace what:="=", replacement:="", lookat:=xlPart
.Replace what:=" ", replacement:="", lookat:=xlPart
.Replace what:=" ", replacement:="", lookat:=xlPart
.Replace what:="{", replacement:="", lookat:=xlPart
.Replace what:="}", replacement:="", lookat:=xlPart
.Replace what:=""",""", replacement:="", lookat:=xlPart
.Replace what:="""", replacement:="", lookat:=xlPart
End With
ActiveCell.Offset(1, 0).Select
ActiveCell.Offset(-1, 0).Select
Selection.Copy
End Sub
thank you in advance for your thoughts, time and ideas !