在同一窗口中打开带有菜单项的表单

时间:2018-12-17 19:50:52

标签: c# forms menustrip

我是博客的新手,我对c#编程有疑问。 我将创建一个Menustrip,但是当我单击具有show show事件的项目时,它将以另一种形式打开。

private void passwordToolStripMenuItem_Click(object sender, EventArgs e)
        {
            GesPass gesPass = new GesPass();
            gesPass.Show();
        }

是否可以在父窗口中打开新表单?

1 个答案:

答案 0 :(得分:0)

您必须设置MdiParent属性,以将子窗体关联到MDI父容器:

2018-12-17T14:52:07.710-05:00 [APP/TASK/7dbf1c0d/0] [ERR] Traceback (most recent call last):
    2018-12-17T14:52:07.710-05:00 [APP/TASK/7dbf1c0d/0] [ERR] File "download_part.py", line 32, in <module>
    2018-12-17T14:52:07.710-05:00 [APP/TASK/7dbf1c0d/0] [ERR] transfer(bucket, access_key, secret_key, file_name, byte_range)
    2018-12-17T14:52:07.710-05:00 [APP/TASK/7dbf1c0d/0] [ERR] File "download_part.py", line 16, in transfer
    2018-12-17T14:52:07.710-05:00 [APP/TASK/7dbf1c0d/0] [ERR] part_object = src_s3.get_object(Bucket=bucket, Key=file_name, Range=byte_range)
    2018-12-17T14:52:07.710-05:00 [APP/TASK/7dbf1c0d/0] [ERR] File "/home/vcap/deps/0/python/lib/python3.5/site-packages/botocore/client.py", line 320, in _api_call
    2018-12-17T14:52:07.710-05:00 [APP/TASK/7dbf1c0d/0] [ERR] return self._make_api_call(operation_name, kwargs)
    2018-12-17T14:52:07.710-05:00 [APP/TASK/7dbf1c0d/0] [ERR] File "/home/vcap/deps/0/python/lib/python3.5/site-packages/botocore/client.py", line 624, in _make_api_call
    2018-12-17T14:52:07.711-05:00 [APP/TASK/7dbf1c0d/0] [ERR] raise error_class(parsed_response, operation_name)
    2018-12-17T14:52:07.711-05:00 [APP/TASK/7dbf1c0d/0] [ERR] botocore.exceptions.ClientError: An error occurred (SignatureDoesNotMatch) when calling the GetObject operation: The request signature we calculated does not match the signature you provided. Check your key and signing method.