这两个问题一直困扰着我,在这里一直找不到帮我解惑之人,你能帮我解决吗?请恕我冒昧。谢谢!!!
1、在多个MDI子窗体同时打开的情况下怎样令其中一个MDI子窗体在最底层显示
2、当按下Button1时datagrid1的allowaddnew和allowupdata都为True,怎样令焦点定位在datagrid1的新增空白行中

解决方案 »

  1.   

    1、
    Private Sub Form_Activate()
    SetWindowPos Me.hwnd, 1, 0, 0, 0, 0, &H1 + &H2 + &H10
    End Sub
    2、
    用SetFocus
      

  2.   

    上面的错的,应该是:
    1、
    Private Sub Form_Activate()
    SetWindowPos Me.hwnd, -1, 0, 0, 0, 0, &H1 + &H2 
    End Sub
    2、
    用SetFocus
      

  3.   

    还要先声明的
    Private Declare Function SetWindowPos Lib "user32" Alias "SetWindowPos" (ByVal hwnd As Long, ByVal hWndInsertAfter As Long, ByVal x As Long, ByVal y As Long, ByVal cx As Long, ByVal cy As Long, ByVal wFlags As Long) As Long