Jump to content

This site uses cookies. By continuing to browse the site you are agreeing to our use of cookies. Find out more here. X
X


Photo

Array file and dir list


  • Please log in to reply
34 replies to this topic

#21 GaryFrost

GaryFrost

    I don't need your attitude. I have one of my own

  • Developers
  • 7,854 posts

Posted 14 July 2006 - 05:48 PM

So, because I have folders at work that include folders and no files the first code did not work, but because it continues the loop either way in the second code it worked?


This is true.

Also if the include is fixed it would be a good idea to change the if statement to something like:

If (Not IsArray($FileList) Or @error) Then

SciTE for AutoItDirections for Submitting Standard UDFs

Don't argue with an idiot; people watching may not be able to tell the difference.








#22 nitekram

nitekram

    Ng1-Nf3

  • Active Members
  • PipPipPipPipPipPip
  • 1,871 posts

Posted 14 July 2006 - 07:02 PM

This is true.

Also if the include is fixed it would be a good idea to change the if statement to something like:

If (Not IsArray($FileList) Or @error) Then

I am not sure I understand the difference between the function that you posted and the If statement - looks like it does the same thing? Only @error does not contain a value and the grouping is different - does it matter?

"Sometimes you have to go back to where you started, to get to where you want to go."  "Everybody catches up with everyone, eventually"  "As you teach others, you are really teaching yourself." all by me. From my dad "Do not worry about yesterday, as the only thing that you can control is tomorrow."

Windows_error.gif

How to ask a Question Forum SearchWIKI FAQ Tutorials Original FAQ - AutoIt Snippets - Multple Guis - Interrupting a running functionAnother Send StringRegExp StringRegExp Help RegEX TesterONLINE HELP UDF's Wiki AutoIt PDF AutoItSetOption Macros Wiki Arrays AutoIt Snippets WrapperAutoit Docs SCITE SciteJump - BB MyTopicsProgramming UDFs AutoIt_101 UDFs Form - UDFTutorial - Tutorials - Documentation - IE.AU3Games? - FreeSoftwarePath_Online

 

Spoiler

#23 GaryFrost

GaryFrost

    I don't need your attitude. I have one of my own

  • Developers
  • 7,854 posts

Posted 14 July 2006 - 07:26 PM

I am not sure I understand the difference between the function that you posted and the If statement - looks like it does the same thing? Only @error does not contain a value and the grouping is different - does it matter?


yes it will matter, if you check @error to be equal to 1 only you are going to have problems.

SciTE for AutoItDirections for Submitting Standard UDFs

Don't argue with an idiot; people watching may not be able to tell the difference.


#24 nitekram

nitekram

    Ng1-Nf3

  • Active Members
  • PipPipPipPipPipPip
  • 1,871 posts

Posted 14 July 2006 - 07:33 PM

yes it will matter, if you check @error to be equal to 1 only you are going to have problems.


got you - I will continue over the weekend

thanks for your help!

"Sometimes you have to go back to where you started, to get to where you want to go."  "Everybody catches up with everyone, eventually"  "As you teach others, you are really teaching yourself." all by me. From my dad "Do not worry about yesterday, as the only thing that you can control is tomorrow."

Windows_error.gif

How to ask a Question Forum SearchWIKI FAQ Tutorials Original FAQ - AutoIt Snippets - Multple Guis - Interrupting a running functionAnother Send StringRegExp StringRegExp Help RegEX TesterONLINE HELP UDF's Wiki AutoIt PDF AutoItSetOption Macros Wiki Arrays AutoIt Snippets WrapperAutoit Docs SCITE SciteJump - BB MyTopicsProgramming UDFs AutoIt_101 UDFs Form - UDFTutorial - Tutorials - Documentation - IE.AU3Games? - FreeSoftwarePath_Online

 

Spoiler

#25 nitekram

nitekram

    Ng1-Nf3

  • Active Members
  • PipPipPipPipPipPip
  • 1,871 posts

Posted 18 July 2006 - 03:23 AM

Why does this not work? In the code everything works but the part that I am asking about. Not sure if I code it right, but the first msgbox() shows the file, how come it does not read the second line or anyline?

Plain Text         
#include <GuiConstants.au3> #include <GuiListView.au3> #Include <File.au3> #Include <Array.au3> Dim $Btn_TestScroll, $Btn_Exit, $msg, $Status, $i, $line2 GUICreate("ListView Scroll", 392, 322) $listview = GUICtrlCreateListView("URL List|URL", 40, 30, 310, 149) _GUICtrlListViewSetColumnWidth($listview, 0, $LVSCW_AUTOSIZE_USEHEADER) $Btn_TestScroll = GUICtrlCreateButton("Scroll Test", 150, 230, 90, 40) $Btn_Exit = GUICtrlCreateButton("Exit", 300, 260, 70, 30) $Status = GUICtrlCreateLabel("Remember items are zero-indexed", 0, 302, 392, 20, BitOR($SS_SUNKEN, $SS_CENTER)) GUISetState() _LoadListView($listview) While 1     $msg = GUIGetMsg()     Select         Case $msg = $GUI_EVENT_CLOSE Or $msg = $Btn_Exit             ExitLoop         Case $msg = $Btn_TestScroll             For $i = 10 To 50 Step 10                 _GUICtrlListViewScroll($listview, 0, $i)                 Sleep(500)                 _GUICtrlListViewScroll($listview, 0, $i - ($i * 2))                 Sleep(500)             Next     EndSelect WEnd Exit Func _LoadListView(ByRef $listview)     $dirList = _FileListToArray(@FavoritesDir, '*', 2)     If (Not IsArray($dirList)) and (@error = 1) Then         MsgBox(0, "", "No Files\Folders Found.")         Exit     EndIf         $fileListurl = _FileListToArray(@FavoritesDir, '*.url', 1)     If (Not IsArray($fileListurl)) and (@error = 1) Then         MsgBox(0, "", "No Files\Folders Found.")         Exit     EndIf         For $test3 = 1 To $fileListurl[0]             ; Why does this not work?         MsgBox(0, $fileListurl[$test3], "")         FileOpen($fileListurl[$test3], 0)         $line2 = FileReadLine($fileListurl[$test3], 2)         MsgBox(0, "", $line2)         FileClose($fileListurl[$test3])     ; above code does not work                 GUICtrlCreateListViewItem($fileListurl[$test3] & "|" & "$line2", $listview)     Next         For $TEST1 = 1 To $dirList[0]         GUICtrlCreateListViewItem($dirList[$TEST1], $listview)                         $FileList = _FileListToArray(@FavoritesDir & "\" & $dirList[$TEST1], '*.url', 1)         If (Not IsArray($FileList)) and (@error = 1) Then             MsgBox(0, "", "No Files\Folders Found.")             Exit         EndIf             ;Display $myArray's contents         For $r = 1 To $FileList[0]             GUICtrlCreateListViewItem($dirList[$TEST1] & " :--: " & $FileList[$r], $listview)         Next     Next EndFunc  ;==>_LoadListView

"Sometimes you have to go back to where you started, to get to where you want to go."  "Everybody catches up with everyone, eventually"  "As you teach others, you are really teaching yourself." all by me. From my dad "Do not worry about yesterday, as the only thing that you can control is tomorrow."

Windows_error.gif

How to ask a Question Forum SearchWIKI FAQ Tutorials Original FAQ - AutoIt Snippets - Multple Guis - Interrupting a running functionAnother Send StringRegExp StringRegExp Help RegEX TesterONLINE HELP UDF's Wiki AutoIt PDF AutoItSetOption Macros Wiki Arrays AutoIt Snippets WrapperAutoit Docs SCITE SciteJump - BB MyTopicsProgramming UDFs AutoIt_101 UDFs Form - UDFTutorial - Tutorials - Documentation - IE.AU3Games? - FreeSoftwarePath_Online

 

Spoiler

#26 GaryFrost

GaryFrost

    I don't need your attitude. I have one of my own

  • Developers
  • 7,854 posts

Posted 18 July 2006 - 03:41 AM

    For $test3 = 1 To $fileListurl[0]         $line2 = FileReadLine(@FavoritesDir & "\" & $fileListurl[$test3], 2)         GUICtrlCreateListViewItem($fileListurl[$test3] & "|" & $line2, $listview)     Next

SciTE for AutoItDirections for Submitting Standard UDFs

Don't argue with an idiot; people watching may not be able to tell the difference.


#27 nitekram

nitekram

    Ng1-Nf3

  • Active Members
  • PipPipPipPipPipPip
  • 1,871 posts

Posted 18 July 2006 - 03:46 AM

    For $test3 = 1 To $fileListurl[0]         $line2 = FileReadLine(@FavoritesDir & "\" & $fileListurl[$test3], 2)         GUICtrlCreateListViewItem($fileListurl[$test3] & "|" & $line2, $listview)     Next

Thanks again - I was kinda close, your the best. I wonder why the msgbox() could read the file name?

"Sometimes you have to go back to where you started, to get to where you want to go."  "Everybody catches up with everyone, eventually"  "As you teach others, you are really teaching yourself." all by me. From my dad "Do not worry about yesterday, as the only thing that you can control is tomorrow."

Windows_error.gif

How to ask a Question Forum SearchWIKI FAQ Tutorials Original FAQ - AutoIt Snippets - Multple Guis - Interrupting a running functionAnother Send StringRegExp StringRegExp Help RegEX TesterONLINE HELP UDF's Wiki AutoIt PDF AutoItSetOption Macros Wiki Arrays AutoIt Snippets WrapperAutoit Docs SCITE SciteJump - BB MyTopicsProgramming UDFs AutoIt_101 UDFs Form - UDFTutorial - Tutorials - Documentation - IE.AU3Games? - FreeSoftwarePath_Online

 

Spoiler

#28 nitekram

nitekram

    Ng1-Nf3

  • Active Members
  • PipPipPipPipPipPip
  • 1,871 posts

Posted 18 July 2006 - 04:30 AM

How about this - the first stringsplit only works with [1], but the second one works with [2] - I want the second array.

Plain Text         
#include <GuiConstants.au3> #include <GuiListView.au3> #Include <File.au3> #Include <Array.au3> Dim $Btn_TestScroll, $Btn_Exit, $msg, $Status, $i, $line2 GUICreate("ListView Scroll", 392, 322);need to fix the size $listview = GUICtrlCreateListView("URL List|URL", 40, 30, 310, 149);need to fix the size _GUICtrlListViewSetColumnWidth($listview, 0, $LVSCW_AUTOSIZE_USEHEADER) $Btn_TestScroll = GUICtrlCreateButton("Scroll Test", 150, 230, 90, 40) $Btn_Exit = GUICtrlCreateButton("Exit", 300, 260, 70, 30) $Status = GUICtrlCreateLabel("Remember items are zero-indexed", 0, 302, 392, 20, BitOR($SS_SUNKEN, $SS_CENTER)) GUISetState() _LoadListView($listview) While 1     $msg = GUIGetMsg()     Select         Case $msg = $GUI_EVENT_CLOSE Or $msg = $Btn_Exit             ExitLoop         Case $msg = $Btn_TestScroll             For $i = 10 To 50 Step 10                 _GUICtrlListViewScroll($listview, 0, $i)                 Sleep(500)                 _GUICtrlListViewScroll($listview, 0, $i - ($i * 2))                 Sleep(500)             Next     EndSelect WEnd Exit Func _LoadListView(ByRef $listview)     $dirList = _FileListToArray(@FavoritesDir, '*', 2)     If (Not IsArray($dirList)) and (@error = 1) Then         MsgBox(0, "", "No Files\Folders Found.")         Exit     EndIf         $fileListurl = _FileListToArray(@FavoritesDir, '*.url', 1)     If (Not IsArray($fileListurl)) and (@error = 1) Then         MsgBox(0, "", "No Files\Folders Found.")         Exit     EndIf         For $test3 = 1 To $fileListurl[0]         $line2 = FileReadLine(@FavoritesDir & "\" & $fileListurl[$test3], 2)         $line2 = StringSplit($line2, "=")         $line2 = $line2[1]         GUICtrlCreateListViewItem($fileListurl[$test3] & "|" & $line2, $listview)     Next         For $TEST1 = 1 To $dirList[0]         GUICtrlCreateListViewItem($dirList[$TEST1], $listview)         $FileList = _FileListToArray(@FavoritesDir & "\" & $dirList[$TEST1], '*.url', 1)         If (Not IsArray($FileList)) and (@error = 1) Then             MsgBox(0, "", "No Files\Folders Found.")             Exit         EndIf             ;Display $myArray's contents         For $r = 1 To $FileList[0]             $line3 = FileReadLine(@FavoritesDir & "\" & $dirList[$TEST1] & "\" & $FileList[$r], 2)             $line3 = StringSplit($line3, "=")             $line3 = $line3[2]             GUICtrlCreateListViewItem($dirList[$TEST1] & " :--: " & $FileList[$r] & "|" & $line3, $listview)         Next     Next EndFunc  ;==>_LoadListView


edit - fixed code tags

Edited by nitekram, 18 July 2006 - 04:30 AM.

"Sometimes you have to go back to where you started, to get to where you want to go."  "Everybody catches up with everyone, eventually"  "As you teach others, you are really teaching yourself." all by me. From my dad "Do not worry about yesterday, as the only thing that you can control is tomorrow."

Windows_error.gif

How to ask a Question Forum SearchWIKI FAQ Tutorials Original FAQ - AutoIt Snippets - Multple Guis - Interrupting a running functionAnother Send StringRegExp StringRegExp Help RegEX TesterONLINE HELP UDF's Wiki AutoIt PDF AutoItSetOption Macros Wiki Arrays AutoIt Snippets WrapperAutoit Docs SCITE SciteJump - BB MyTopicsProgramming UDFs AutoIt_101 UDFs Form - UDFTutorial - Tutorials - Documentation - IE.AU3Games? - FreeSoftwarePath_Online

 

Spoiler

#29 nitekram

nitekram

    Ng1-Nf3

  • Active Members
  • PipPipPipPipPipPip
  • 1,871 posts

Posted 18 July 2006 - 01:49 PM

bump

"Sometimes you have to go back to where you started, to get to where you want to go."  "Everybody catches up with everyone, eventually"  "As you teach others, you are really teaching yourself." all by me. From my dad "Do not worry about yesterday, as the only thing that you can control is tomorrow."

Windows_error.gif

How to ask a Question Forum SearchWIKI FAQ Tutorials Original FAQ - AutoIt Snippets - Multple Guis - Interrupting a running functionAnother Send StringRegExp StringRegExp Help RegEX TesterONLINE HELP UDF's Wiki AutoIt PDF AutoItSetOption Macros Wiki Arrays AutoIt Snippets WrapperAutoit Docs SCITE SciteJump - BB MyTopicsProgramming UDFs AutoIt_101 UDFs Form - UDFTutorial - Tutorials - Documentation - IE.AU3Games? - FreeSoftwarePath_Online

 

Spoiler

#30 GaryFrost

GaryFrost

    I don't need your attitude. I have one of my own

  • Developers
  • 7,854 posts

Posted 18 July 2006 - 02:02 PM

works for me here and at home.

AutoIt         
#include <GuiConstants.au3> #include <GuiListView.au3> #Include <File.au3> #Include <Array.au3> Dim $Btn_TestScroll, $Btn_Exit, $msg, $Status, $i, $line2 GUICreate("ListView Scroll", 392, 322);need to fix the size $listview = GUICtrlCreateListView("URL List|URL", 40, 30, 310, 149);need to fix the size _GUICtrlListViewSetColumnWidth($listview, 0, $LVSCW_AUTOSIZE_USEHEADER) $Btn_TestScroll = GUICtrlCreateButton("Scroll Test", 150, 230, 90, 40) $Btn_Exit = GUICtrlCreateButton("Exit", 300, 260, 70, 30) $Status = GUICtrlCreateLabel("Remember items are zero-indexed", 0, 302, 392, 20, BitOR($SS_SUNKEN, $SS_CENTER)) GUISetState() _LoadListView($listview) While 1     $msg = GUIGetMsg()     Select         Case $msg = $GUI_EVENT_CLOSE Or $msg = $Btn_Exit             ExitLoop         Case $msg = $Btn_TestScroll             For $i = 10 To 50 Step 10                 _GUICtrlListViewScroll($listview, 0, $i)                 Sleep(500)                 _GUICtrlListViewScroll($listview, 0, $i - ($i * 2))                 Sleep(500)             Next     EndSelect WEnd Exit Func _LoadListView(ByRef $listview)     $dirList = _FileListToArray(@FavoritesDir, '*', 2)     If (Not IsArray($dirList)) and (@error = 1) Then         MsgBox(0, "", "No Files\Folders Found.")         Exit     EndIf         $fileListurl = _FileListToArray(@FavoritesDir, '*.url', 1)     If (Not IsArray($fileListurl)) and (@error = 1) Then         MsgBox(0, "", "No Files\Folders Found.")         Exit     EndIf         For $test3 = 1 To $fileListurl[0]         $line2 = FileReadLine(@FavoritesDir & "\" & $fileListurl[$test3], 2)         $line2 = StringSplit($line2, "=")         $line2 = $line2[2]         GUICtrlCreateListViewItem($fileListurl[$test3] & "|" & $line2, $listview)     Next         For $TEST1 = 1 To $dirList[0]         GUICtrlCreateListViewItem($dirList[$TEST1], $listview)         $FileList = _FileListToArray(@FavoritesDir & "\" & $dirList[$TEST1], '*.url', 1)         If (Not IsArray($FileList) Or @error) Then ;~             MsgBox(0, "", "No Files\Folders Found.")             ContinueLoop         EndIf             ;Display $myArray's contents         For $r = 1 To $FileList[0]             $line3 = FileReadLine(@FavoritesDir & "\" & $dirList[$TEST1] & "\" & $FileList[$r], 2)             $line3 = StringSplit($line3, "=")             $line3 = $line3[2]             GUICtrlCreateListViewItem($dirList[$TEST1] & " :--: " & $FileList[$r] & "|" & $line3, $listview)         Next     Next EndFunc  ;==>_LoadListView

SciTE for AutoItDirections for Submitting Standard UDFs

Don't argue with an idiot; people watching may not be able to tell the difference.


#31 nitekram

nitekram

    Ng1-Nf3

  • Active Members
  • PipPipPipPipPipPip
  • 1,871 posts

Posted 18 July 2006 - 02:41 PM

I copied your script and got the same error message I was receiving on both home and work.

>Running: (3.1.1.111):C:\Program Files\AutoIt3\beta\autoit3.exe "Z:\scripts\URL_lister.au3"
Z:\scripts\URL_lister.au3 (55) : ==> Array variable has incorrect number of subscripts or subscript dimension range exceeded.:
$line2 = $line2[2]
$line2 = ^ ERROR

"Sometimes you have to go back to where you started, to get to where you want to go."  "Everybody catches up with everyone, eventually"  "As you teach others, you are really teaching yourself." all by me. From my dad "Do not worry about yesterday, as the only thing that you can control is tomorrow."

Windows_error.gif

How to ask a Question Forum SearchWIKI FAQ Tutorials Original FAQ - AutoIt Snippets - Multple Guis - Interrupting a running functionAnother Send StringRegExp StringRegExp Help RegEX TesterONLINE HELP UDF's Wiki AutoIt PDF AutoItSetOption Macros Wiki Arrays AutoIt Snippets WrapperAutoit Docs SCITE SciteJump - BB MyTopicsProgramming UDFs AutoIt_101 UDFs Form - UDFTutorial - Tutorials - Documentation - IE.AU3Games? - FreeSoftwarePath_Online

 

Spoiler

#32 GaryFrost

GaryFrost

    I don't need your attitude. I have one of my own

  • Developers
  • 7,854 posts

Posted 18 July 2006 - 03:19 PM

try with more error checking

AutoIt         
#include <GuiConstants.au3> #include <GuiListView.au3> #Include <File.au3> #Include <Array.au3> Dim $Btn_TestScroll, $Btn_Exit, $msg, $Status, $i, $line2 GUICreate("ListView Scroll", 392, 322);need to fix the size $listview = GUICtrlCreateListView("URL List|URL", 40, 30, 310, 149);need to fix the size _GUICtrlListViewSetColumnWidth($listview, 0, $LVSCW_AUTOSIZE_USEHEADER) $Btn_TestScroll = GUICtrlCreateButton("Scroll Test", 150, 230, 90, 40) $Btn_Exit = GUICtrlCreateButton("Exit", 300, 260, 70, 30) $Status = GUICtrlCreateLabel("Remember items are zero-indexed", 0, 302, 392, 20, BitOR($SS_SUNKEN, $SS_CENTER)) GUISetState() _LoadListView($listview) While 1     $msg = GUIGetMsg()     Select         Case $msg = $GUI_EVENT_CLOSE Or $msg = $Btn_Exit             ExitLoop         Case $msg = $Btn_TestScroll             For $i = 10 To 50 Step 10                 _GUICtrlListViewScroll($listview, 0, $i)                 Sleep(500)                 _GUICtrlListViewScroll($listview, 0, $i - ($i * 2))                 Sleep(500)             Next     EndSelect WEnd Exit Func _LoadListView(ByRef $listview)     $dirList = _FileListToArray(@FavoritesDir, '*', 2)     If (Not IsArray($dirList)) and (@error = 1) Then         MsgBox(0, "", "No Files\Folders Found.")         Exit     EndIf         $fileListurl = _FileListToArray(@FavoritesDir, '*.url', 1)     If (Not IsArray($fileListurl)) and (@error = 1) Then         MsgBox(0, "", "No Files\Folders Found.")         Exit     EndIf         For $test3 = 1 To $fileListurl[0]         $line2 = FileReadLine(@FavoritesDir & "\" & $fileListurl[$test3], 2)         $line2 = StringSplit($line2, "=")         If Not @error And $line2[0] > 1 Then             $line2 = $line2[2]             GUICtrlCreateListViewItem($fileListurl[$test3] & "|" & $line2, $listview)         EndIf     Next         For $TEST1 = 1 To $dirList[0]         GUICtrlCreateListViewItem($dirList[$TEST1], $listview)         $FileList = _FileListToArray(@FavoritesDir & "\" & $dirList[$TEST1], '*.url', 1)         If (Not IsArray($FileList) Or @error) Then ;~             MsgBox(0, "", "No Files\Folders Found.")             ContinueLoop         EndIf                 ;Display $myArray's contents         For $r = 1 To $FileList[0]             $line3 = FileReadLine(@FavoritesDir & "\" & $dirList[$TEST1] & "\" & $FileList[$r], 2)             $line3 = StringSplit($line3, "=")             If Not @error And $line3[0] > 1 Then                 $line3 = $line3[2]                 GUICtrlCreateListViewItem($dirList[$TEST1] & " :--: " & $FileList[$r] & "|" & $line3, $listview)             EndIf         Next     Next EndFunc   ;==>_LoadListView

SciTE for AutoItDirections for Submitting Standard UDFs

Don't argue with an idiot; people watching may not be able to tell the difference.


#33 nitekram

nitekram

    Ng1-Nf3

  • Active Members
  • PipPipPipPipPipPip
  • 1,871 posts

Posted 18 July 2006 - 03:47 PM

try with more error checking


That worked - can you explain it to me though. I have not done anything with error handling and have tired to read the help file and got lost. Does anyone have a detailed explanation of what it does and how it works?

I guess the reason that I am asking is I want to learn, but also @gafrost stated his worked at home and work - so how come my did not?

I have used my own error checking to make sure a variable matches the type I want coming from an end user - just not sure of @ERROR or SetError () - any help would make me post less :D

"Sometimes you have to go back to where you started, to get to where you want to go."  "Everybody catches up with everyone, eventually"  "As you teach others, you are really teaching yourself." all by me. From my dad "Do not worry about yesterday, as the only thing that you can control is tomorrow."

Windows_error.gif

How to ask a Question Forum SearchWIKI FAQ Tutorials Original FAQ - AutoIt Snippets - Multple Guis - Interrupting a running functionAnother Send StringRegExp StringRegExp Help RegEX TesterONLINE HELP UDF's Wiki AutoIt PDF AutoItSetOption Macros Wiki Arrays AutoIt Snippets WrapperAutoit Docs SCITE SciteJump - BB MyTopicsProgramming UDFs AutoIt_101 UDFs Form - UDFTutorial - Tutorials - Documentation - IE.AU3Games? - FreeSoftwarePath_Online

 

Spoiler

#34 GaryFrost

GaryFrost

    I don't need your attitude. I have one of my own

  • Developers
  • 7,854 posts

Posted 18 July 2006 - 03:53 PM

That worked - can you explain it to me though. I have not done anything with error handling and have tired to read the help file and got lost. Does anyone have a detailed explanation of what it does and how it works?

I guess the reason that I am asking is I want to learn, but also @gafrost stated his worked at home and work - so how come my did not?

I have used my own error checking to make sure a variable matches the type I want coming from an end user - just not sure of @ERROR or SetError () - any help would make me post less :D

1st thing i did was to see what happens with stringsplit:

1 - delimiter found
2 - delmiter not found: @error is set and the array[0] is set to 1

So that made me think there might be a problem with a few files on your system(s).

SciTE for AutoItDirections for Submitting Standard UDFs

Don't argue with an idiot; people watching may not be able to tell the difference.


#35 nitekram

nitekram

    Ng1-Nf3

  • Active Members
  • PipPipPipPipPipPip
  • 1,871 posts

Posted 18 July 2006 - 04:19 PM

1st thing i did was to see what happens with stringsplit:

1 - delimiter found
2 - delmiter not found: @error is set and the array[0] is set to 1

So that made me think there might be a problem with a few files on your system(s).

I got you - but that also means that the files that broke it are not being displayed - right? I will have to set up a condition for those where I do not split the string and it shows - maybe in a different color font would work.

I know that this will be an on going issue as I have tried to copy files with windows before and got stuck because of a weird character in the file name (how come they just don't check at the start of the saving of the file - I will never know) - anyway if anyone is interested in the program that I found for coping any files and gives a break out of the bad ones it is YCOPY - but does anyone have something written in AutoIT for this same functionality?

"Sometimes you have to go back to where you started, to get to where you want to go."  "Everybody catches up with everyone, eventually"  "As you teach others, you are really teaching yourself." all by me. From my dad "Do not worry about yesterday, as the only thing that you can control is tomorrow."

Windows_error.gif

How to ask a Question Forum SearchWIKI FAQ Tutorials Original FAQ - AutoIt Snippets - Multple Guis - Interrupting a running functionAnother Send StringRegExp StringRegExp Help RegEX TesterONLINE HELP UDF's Wiki AutoIt PDF AutoItSetOption Macros Wiki Arrays AutoIt Snippets WrapperAutoit Docs SCITE SciteJump - BB MyTopicsProgramming UDFs AutoIt_101 UDFs Form - UDFTutorial - Tutorials - Documentation - IE.AU3Games? - FreeSoftwarePath_Online

 

Spoiler




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users