나눔터  
  HOME > 나눔터 > 묻고답하기 > 파워포인트
파워포인트
파워포인트에 대한 질문과 답변을 올려주세요. 단, 취지에 맞지 않는 글은 운영자가 삭제합니다.
 "000 님, 도와주세요", "부탁 드립니다.", "급합니다!" 등과 같이 막연한 제목을 달지 말아주세요.
[필독] 빠르고 정확한 답변을 얻는 16가지 Tip !
[필독] 저작권법 개정에 따른 이용안내
작성자:  

 이중광 (wrwrw)

추천:  3
파일:     조회:  1449
제목:   [RE]특정 ppt 숨기기
     
  안녕하세요 ist공원님^^

일반적인 방법으로는 불가능해보이는군요 ㅎㅎ;;
이건 WIN32API함수를 사용해야될것 같습니다.
아래코드를 보시면 pptEnable프로시져와 Test프로시져가 있습니다.
Test프로시저를 실행시키면 2번째 프리젠테이션을 숨기기&사용불가능으로 설정합니다.
궁굼하신점이 있으시면 말씀해주세요. 
그럼 좋은 하루되세요^^

Option Explicit
Public Declare Function FindWindow Lib "user32" Alias "FindWindowA" (ByVal lpClassName As String, ByVal lpWindowName As String) As Long
Public Declare Function FindWindowEx Lib "user32" Alias "FindWindowExA" (ByVal hWnd1 As Long, ByVal hWnd2 As Long, ByVal lpsz1 As String, ByVal lpsz2 As String) As Long
Public Declare Function EnableWindow Lib "user32" (ByVal hWnd As Long, ByVal fEnable As Long) As Long
Public Declare Function IsWindowEnabled Lib "user32" (ByVal hWnd As Long) As Long
Public Declare Function LockWindowUpdate Lib "user32" (ByVal hwndLock As Long) As Long

Sub Test()
    pptEnable Presentations(2), False
End Sub

Sub pptEnable(Pres As Presentation, Enabled As Boolean)
Dim hWnd As Long, hMDIClient As Long
hWnd = FindWindow("PP11FrameClass", vbNullString)
hMDIClient = FindWindowEx(hWnd, ByVal 0&, "MDIClient", vbNullString)
LockWindowUpdate hWnd
Dim Win As DocumentWindow
    For Each Win In Pres.Windows
        hWnd = FindWindowEx(hMDIClient, ByVal 0&, "mdiClass", Win.Caption)
        EnableWindow hWnd, Enabled
        Win.WindowState = ppWindowMinimized
    Next
    For Each Win In Windows
       If IsWindowEnabled(FindWindowEx(hMDIClient, ByVal 0&, "mdiClass", Win.Caption)) > 0 Then
            Win.WindowState = ppWindowMaximized
            Exit For
        End If
    Next
LockWindowUpdate 0
End Sub
 
[불량 게시물 신고]  
ist공원이건 너무 어렵군요...^^
조금 더 내공이 쌓이면 이해가 될지도...
답변 주셔서 감사드립니다.
10-01 (16:39)
삭제 ■신고
        
  

작성일 : 2006-09-30(22:15)
최종수정일 : 2006-09-30(22:15)
 


 ◎ 관련글

  제 목   작성자   날짜
특정 ppt 숨기기 ist공원 2006-09-30
[RE]특정 ppt 숨기기 이중광 2006-09-30