May 12 2022 02:18 AM
Hi, I have an Excel Workbook Having 5(Five) No’s of Excel Sheet in named 1) DASH BOARD,2) Sheet1,3) Sheet2,4) Sheet3,5) Sheet4. In DASH BOARD Sheet there is 4(Four) No’s Button exist in named GoToSheet1, GoToSheet2, GoToSheet3, GoToSheet4, by on which pressing I go to schedule Sheet. For this I have VBA Code as below. This Excel Book looks as is usually the case with normal Excel Book.
Sub Go_To_Sheet1()
ThisWorkbook.Sheets("Sheet1").Activate
End Sub
Sub Go_To_Sheet2()
ThisWorkbook.Sheets("Sheet2").Activate
End Sub
Sub Go_To_Sheet3()
ThisWorkbook.Sheets("Sheet3").Activate
End Sub
Sub Go_To_Sheet4()
ThisWorkbook.Sheets("Sheet4").Activate
End Sub
Now I want VBA Code to hiding of 4(Four)Excel Sheet (Sheet1, Sheet2, Sheet3, Sheet4) except “DASH BOARD” Excel Sheet of this Excel Workbook. Actually when I want to open this Excel Workbook, only “DASH BOARD” Excel Sheet will be visible. When I want to perform any Excel Sheet of this Excel Workbook so that I can open the Excel Sheet by clicking same named BUTTON. After that the schedule Excel Sheet will be disappear by close (X) when task is complete, and again “DASH BOARD” Sheet will be visible only. Being new to VBA looking for VBA Code in this regards
May 12 2022 02:36 AM
SolutionSee the attached sample workbook. Code in Module1 and in ThisWorkbook.
May 14 2022 02:37 AM
May 14 2022 03:31 AM
With so many sheets, I'd do it differently. Instead of a button for each sheet, I'd use a drop-down list to select the sheet, and just one button. See the attached version.
May 16 2022 05:06 AM
May 25 2023 04:29 AM
Bom dia,
Preciso de uma macro que pesquise por setor toda vez que eu inserir a palavra "pendente" no campo Status Kaizen e apareça como uma lista no campo Manchete das ideias , buscando dentro da aba "AMBIENTE CONSULTA GERAL",permitindo que eu abra com um botão de comando o formulário já filtrado de acordo com o campo Status Kaizen. E ao selecionar e editar o campo na COLUNA I (prazo Análise Setor) a data apareça no dentro do formulário no campo do Prazo Análise Setor. E tenha um botão de gravar a informação e passar para linha seguinte.Montei o formulário mas não sei qual macro inserir.
Segue exemplo da base dados
May 25 2023 04:38 AM
Você poderia anexar uma pequena pasta de trabalho de amostra demonstrando o problema (sem dados confidenciais) ou, se isso não for possível, disponibilizá-la por meio do OneDrive, Google Drive, Dropbox ou similar?
Jan 14 2024 12:23 PM - edited Jan 14 2024 12:24 PM
That's pretty common.
Sub HideSheets() 'hide sheets not named DASHBOARD
Dim i As Integer, Sh1 As String
For i = 1 To ThisWorkbook.Sheets.Count
Sh1 = Sheets(i).Name
On Error Resume Next
If Sh1 <> "DASHBOARD" Then
Sheets(Sh1).Visible = xlSheetHidden
End If
Next i
End Sub
Sub UnHideSheets() 'unhide sheets
Dim i As Integer
For i = 1 To ThisWorkbook.Sheets.Count
On Error Resume Next
Sheets(i).Visible = xlSheetVisible
Next i
End Sub
May 12 2022 02:36 AM
SolutionSee the attached sample workbook. Code in Module1 and in ThisWorkbook.