我正在使用 Windows 移动应用程序 .. 正是它 Microsoft.WindowsMobile.Samples.CECamera
当我捕获图像时,会出现一个对话框,告诉它已成功捕获,我应该单击确定。在代码中,它使用这个确定点击继续保存图片......现在我希望这条消息停止出现。或任何其他方法来自动单击该确定按钮。
if (DialogResult.OK == cameraCapture.ShowDialog())
{
string fileName = cameraCapture.FileName;
// If it is a video we rename the file so that it has the user entered
// default filename and the correct extension.
if (cameraCapture.Mode != CameraCaptureMode.Still)
{
string extension = fileName.Substring(fileName.LastIndexOf("."));
string directory = "";
if (fileName.LastIndexOf("\\") != -1)
{
directory = fileName.Substring(0, fileName.LastIndexOf("\\") + 1);
}
fileName = directory + this.textDefaultFileName.Text + extension;
System.IO.File.Move(cameraCapture.FileName, fileName);
}
// The method completed successfully.
MessageBox.Show("The picture or video has been successfully captured and saved to:\n\n" + fileName,
this.Text, MessageBoxButtons.OK, MessageBoxIcon.Asterisk, MessageBoxDefaultButton.Button1);
}
}