如何在VB.NET visual studio 2005中检查图像大小 [英] How to check image size in VB.NET visual studio 2005

查看:102
本文介绍了如何在VB.NET visual studio 2005中检查图像大小的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我需要在使用打开的对话框控件选择图像时检查图像大小。我参考许多代码但它们不工作



什么我试过了:



I need to check Image size at the time of selecting image using open dialog box control.I refer many codes but they are not working

What I have tried:

If  Dim info as New FileInfo(.FileName).Length < 50 Then







错误信息是

表达式预期。




the error message is
Expression Expected.

推荐答案

尝试将上述语句拆分为:

Try to split above statement into:
Dim fi As FileInfo = New FileInfo(.FileName)
If fi.Length < 50 Then
   '...
End If





详情请见:文件信息类(System.IO)| Microsoft Docs [ ^ ]



祝你好运!



For further details, please see: FileInfo Class (System.IO) | Microsoft Docs[^]

Good luck!


这篇关于如何在VB.NET visual studio 2005中检查图像大小的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆