Openfiledialog filter

If you need help with a project or need to know how to do something specific in VB.NET then please ask your questions in here.
Forum rules
Please LOCK your topics once you have found the solution to your question so we know you no longer require help with your query.
4 posts Page 1 of 1
Contributors
User avatar
AnoPem
VIP - Donator
VIP - Donator
Posts: 441
Joined: Sat Jul 24, 2010 10:55 pm

Openfiledialog filter
AnoPem
Is it possible to get the openfiledialog only to accept if the file name of the selected file is ex. "javaw.exe so it wont accept "java.exe"?
Last edited by AnoPem on Sun Apr 08, 2012 9:12 pm, edited 1 time in total.
https://t.me/pump_upp
User avatar
clanc789
Coding Guru
Coding Guru
Posts: 786
Joined: Tue Nov 02, 2010 4:45 pm

Re: Openfiledialog filter
clanc789
I thought that was possible with smth alike this:
Code: Select all
If openfiledialog.result = "result.exe" then
'run
else
'end or smth
Did not test it so dont know for sure if it works.
Practice makes perfect!

VIP since: 6-10-2011
User avatar
MrAksel
C# Coder
C# Coder
Posts: 1758
Joined: Fri Mar 26, 2010 12:27 pm

Re: Openfiledialog filter
MrAksel
Code: Select all
OpenFileDialog1.Filter = "Javaw|Javaw.exe"
LMAOSHMSFOAIDMT
Laughing my a** of so hard my sombrero fell off and I dropped my taco lmao;


Over 30 projects with source code!
Please give reputation to helpful members!

Image
Image
User avatar
AnoPem
VIP - Donator
VIP - Donator
Posts: 441
Joined: Sat Jul 24, 2010 10:55 pm

Re: Openfiledialog filter
AnoPem
MrAksel wrote:
Code: Select all
OpenFileDialog1.Filter = "Javaw|Javaw.exe"
Thank you :)
https://t.me/pump_upp
4 posts Page 1 of 1
Return to “Coding Help & Support”