Sign in to follow this  
Followers 0
Gif

string symbols

3 posts in this topic

#1 ·  Posted (edited)

i have a couple of strings and i want to get only the strings that are paths (that dont exist)

the strings are pretty much like this

@themenu.dll -192 (dont want this)

C:\Windows\system32... (i want this)

LangID (dont want this)

anyway to get the paths?

i tried this

If Not StringInStr($con, "@") Or StringInStr($con, "-") Then 
If Not FileExists($con) Then GUICtrlCreateListViewItem($con & "|" & $selected, $ListView)
EndIf

but again it returns all the values...

thanks in advance!

oh dear thats a silly post, found the solution quickly

Edited by c4nm7

Share this post


Link to post
Share on other sites



$path = 'C:\Windows\system32'

If FileExists($path) And StringInStr(FileGetAttrib($path), 'D') Then MsgBox(0, '', 'It''s a folder!')

Share this post


Link to post
Share on other sites

#3 ·  Posted (edited)

$path = 'C:\Windows\system32'

If FileExists($path) And StringInStr(FileGetAttrib($path), 'D') Then MsgBox(0, '', 'It''s a folder!')

its ok i found the solution and this wouldnt work cause i want a path thats DOESNT EXISTS so i couldnt check for this strings for a path cause non of these sttrings exists...

here is the solution:

If Not StringInStr($con, "@") And StringTrimLeft($con, 6) Then 
If Not FileExists($con) Then GUICtrlCreateListViewItem($con & "|" & $selected, $ListView)
EndIf
Edited by c4nm7

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0