【问题标题】:VB.NET Debug ErrorVB.NET 调试错误
【发布时间】:2011-02-08 10:35:18
【问题描述】:

我收到此代码的“路径中的非法字符”错误:

Dim strm As System.IO.FileStream
strm = New System.IO.FileStream(filepath, IO.FileMode.Open, IO.FileAccess.Read)

【问题讨论】:

  • 文件路径是什么?
  • 了解如何使用监视窗口来跟踪变量值。 IO.Path.InvalidPathChars 中列出了非法字符

标签: vb.net debugging illegal-characters


【解决方案1】:

您的文件路径可能包含 Windows 文件系统不允许使用的无效字符,例如 \ / : * ? " < > |

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 2016-12-21
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2018-03-12
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多