Advertisement
coinb0y

Excel Macros for Huobi Copy/Paste Formatting

Feb 9th, 2018
548
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. Sub TransposeTransactionHistroy()
  2.     Dim i&, z&, x&
  3.     i = Cells(Rows.Count, "A").End(xlUp).Row
  4.     z = 1
  5.     x = 2  ' Leave room for a header row
  6.    While z <= i
  7.         Range("B" & x).Resize(, 8) = WorksheetFunction.Transpose(Range("A" & z).Resize(8))
  8.         z = z + 8
  9.         x = x + 1
  10.     Wend
  11. End Sub
  12.  
  13. Sub TransposeDepositHistory()
  14.     Dim i&, z&, x&
  15.     i = Cells(Rows.Count, "A").End(xlUp).Row
  16.     z = 1
  17.     x = 2  ' Leave room for a header row
  18.    While z <= i
  19.         Range("B" & x).Resize(, 5) = WorksheetFunction.Transpose(Range("A" & z).Resize(5))
  20.         z = z + 8
  21.         x = x + 1
  22.     Wend
  23. End Sub
  24.  
  25. Sub TransposeWithdrawalHistory()
  26.     Dim i&, z&, x&
  27.     i = Cells(Rows.Count, "A").End(xlUp).Row
  28.     z = 1
  29.     x = 2  ' Leave room for a header row
  30.    While z <= i
  31.         Range("B" & x).Resize(, 5) = WorksheetFunction.Transpose(Range("A" & z).Resize(5))
  32.         z = z + 9
  33.         x = x + 1
  34.     Wend
  35. End Sub
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement