user define function to concatenate the non empty cells
For Example:-
function given below--
Function connonempty(x As Range) As String
Dim y As Range
Dim hh As String
hh = ""
For Each y In x
If Not IsEmpty(y) Then
hh = hh & y & ","
End If
Next y
If Right(hh, 1) = "," Then
hh = Left(hh, Len(hh) - 1)
End If
connonempty = hh
End Function
type like : =connonempty(B2:H2)
Subscribe to:
Post Comments (Atom)
Import data from SQL
Macro to import data from SQL using ADO connection string: Sub Import_data_from_SQL() ' Tools -> References -> Microsoft Active...
-
If you want to copy the data from pdf file to Excel. Sub method1_using_sendkey() Dim task ' open the file ' change the path of ...
-
Macro to import data from SQL using ADO connection string: Sub Import_data_from_SQL() ' Tools -> References -> Microsoft Active...
No comments:
Post a Comment