Permalink
Browse files

Doc update

  • Loading branch information...
1 parent dffeb21 commit 3691ddf48787083ece4415faed74aaeda4a844d7 @emilefyon committed Sep 2, 2012
Showing with 35 additions and 15 deletions.
  1. +2 −2 LIB_Regex.bas
  2. +33 −13 LIB_Workbook.bas
View
@@ -158,11 +158,11 @@ End Function
' - ByVal txt As String : the text to search in
'
'
-' Last edition date : 11/07/2012
+' Last edition date : 02/09/2012
'
' Revisions history
' -----------------
-' - Emile Fyon 11/07/2012 Creation
+' - Emile Fyon 02/09/2012 Creation
'
'---------------------------------------------------------------------------------------------------------------------------------------------
View
@@ -59,29 +59,26 @@ End Function
'---------------------------------------------------------------------------------------------------------------------------------------------
-' + Function moveSheetsInCurrentWorkbook() As String
+' + Function moveSheetsInCurrentWorkbook(ByVal wkFullPath As String, Optional ByVal namePattern As String) As String
' * Description : Return the path of the current workbook
' * Specifications / limitations
' - None
' * Arguments
-' - None
+' - wkFullPath : the fullPath of the workbook to import the worksheets from
+' - namePattern : a custom name Pattern
+' #wkName will be replaced is with the name of the destination workbook
+' #wsName will be the current name of the worksheet
'
'
' Last edition date : 11/07/2012
'
' Revisions history
' -----------------
' - Emile Fyon 11/07/2012 Creation
+' - Emile Fyon 02/09/2012 Revision in order to make the function ActiveCell-free
'
'---------------------------------------------------------------------------------------------------------------------------------------------
-Sub test()
-
- Call moveSheetsInCurrentWorkbook(ActiveCell.Value)
-
-End Sub
-
-
Sub moveSheetsInCurrentWorkbook(ByVal wkFullPath As String, Optional ByVal namePattern As String)
Dim wkFileName As String
Dim wsCurrent As Worksheet
@@ -170,14 +167,37 @@ Sub getReplacementPatterns()
End Sub
+'---------------------------------------------------------------------------------------------------------------------------------------------
+' + Function listSheets() As String
+' * Description : Write the name of the worksheets of the current workbook in a destination cell
+' * Specifications / limitations
+' - None
+' * Arguments
+' - wkFullPath : the fullPath of the workbook to import the worksheets from
+' - namePattern : a custom name Pattern
+' #wkName will be replaced is with the name of the destination workbook
+' #wsName will be the current name of the worksheet
+'
+'
+' Last edition date : 11/07/2012
+'
+' Revisions history
+' -----------------
+' - Emile Fyon 11/07/2012 Creation
+' - Emile Fyon 02/09/2012 Revision in order to make the function ActiveCell-free
+'
+'---------------------------------------------------------------------------------------------------------------------------------------------
+
-Sub listSheets()
+Sub listSheets(Optional ByVal destRg As Range)
Dim rg As Range
- Do
- Set rg = Application.InputBox(Prompt:="Where do you want to copy the list of sheets ?", Title:="Choose a range", Type:=8)
- Loop While rg Is Nothing
+ If IsMissing(destRg) Then
+ Do
+ Set rg = Application.InputBox(Prompt:="Where do you want to copy the list of sheets ?", Title:="Choose a range", Type:=8)
+ Loop While rg Is Nothing
+ End If
i = 0
For Each ws In ActiveWorkbook.Sheets

0 comments on commit 3691ddf

Please sign in to comment.