Jump to content
Sign in to follow this  
dutCh

MAX_LINESIZE confine arrays

Recommended Posts

dutCh

Hello!

First of all I appreciate this great tool. It fills for me the gap between the-one-and-only-and-best-thing C and batch programming/regular expressions in Ultraedit.

But why must the MAX_LINESIZE constant confine array defines? multi dim arrays!!?

Maximum length of a single script line: 4,095

Maximum string length: 2,147,483,647 characters //schön wärs!!

Why must such a cool tool break down with such a stupid bug (sorry!)

One could realize when "]," occurs and than, with or w.o. whitespace, an "[" - he should not break and not exit with an error, he should simlpe dim this array... ;-(

I think about to revert to C an write something like AutoItHelper.DLL!SupplyBigArrays

Or maybe I'm wrong and overlooked something?

PS: I attach my little prog. i like it. kurz und knackig! :-)

i definetivly not plan to botch it with parsing orgies!

Thank you.

dutCh

Norton95.au3


[font="Courier New"]C rulez![/font]

Share this post


Link to post
Share on other sites
Richard Robertson

You are missing a _ character on the first line of your large array declaration. It just stopped at ]

["w", "Norton Commander", "Willkommen bei Symantec Setup", "", "", "", "", ""]

There's no _.

Share this post


Link to post
Share on other sites
ResNullius

Not related to the issue you're having, but since I see you a Norton Commander user, have you checked out FAR: File & Archive manager?

http://farmanager.com/?l=en

I was a devoted Norton Commander fan, and FAR is the closest thing I've found that is compatible with latter versions of Windows.

Share this post


Link to post
Share on other sites
dutCh

You are missing a _ character on the first line of your large array declaration. It just stopped at ]

There's no _.

You're right, but that's not the reason. It's a relikt from my try with a single dim array. Compile it (not only just check it!) and see for yourself.

I'm astonished thats no one else ponder on this enervating and unnecessary bug.

Thanx.

dutCh


[font="Courier New"]C rulez![/font]

Share this post


Link to post
Share on other sites
dutCh

Not related to the issue you're having, but since I see you a Norton Commander user, have you checked out FAR: File & Archive manager?

http://farmanager.com/?l=en

I was a devoted Norton Commander fan, and FAR is the closest thing I've found that is compatible with latter versions of Windows.

I don't like "latter versions of windows"! I love the most Win98SE + Ultraedit + SoftICE... and Linux :-)

I personally still use the famous Norton4. The NC95 Installer is for my chef... and a training session in AutoIt. :-)

thanx man.


[font="Courier New"]C rulez![/font]

Share this post


Link to post
Share on other sites
dutCh

PS: I attach my little prog.

Let me be completely accurate. The error appears only when you run the script with autoit3.exe

AU3Check and Aut2exe find everything okay.

And please add the " _" chars on line 27. (sorry)

-----

dutCh


[font="Courier New"]C rulez![/font]

Share this post


Link to post
Share on other sites
Richard Robertson

Ah. I do see what you've run into now. I'm afraid you'll just have to find some other way to add the information to the array.

The error though was a bit odd. It said it was missing an end bracket and showed a right parenthesis instead of a square bracket. ')'

Share this post


Link to post
Share on other sites
Bowmore

One way to do this is to store the array data in a delimited text file and then use _FileReadToArray() and StringSplit() to populate your array.

Below is a simple example of this method to give you some ideas.

#include <Array.au3>
#include <file.au3>

Dim $aMyArray[100][8]
Dim $aTemp = 0
Dim $aRow = 0

_FileReadToArray("Array Data.txt", $aTemp)
If IsArray($aTemp) Then
    For $iRow = 1 To UBound($aTemp) - 1 Step 1
        $aRow = StringSplit($aTemp[$iRow],"|")
        If IsArray($aRow) Then
            For $iCol = 1 To $aRow[0] Step 1
                $aMyArray[$iRow - 1][$iCol - 1] = $aRow[$iCol] 
            Next
        EndIf
    Next
EndIf
$aTemp = 0
$aRow = 0

_ArrayDisplay($aMyArray,"$aMyArray")


"Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the universe trying to build bigger and better idiots. So far, the universe is winning."- Rick Cook

Share this post


Link to post
Share on other sites
dutCh

Ah. I do see what you've run into now. I'm afraid you'll just have to find some other way to add the information to the array.

Yipp, i'm too. But it hurts me to tear up this nice looking block of code.

I experiment with a splited 2-dim array. but cant find a way to say a string is an array:

Dim $aDlg1[2][2] = [["t111", "t112"], ["t121", "t122"]]

Dim $aDlg2[2][2] = [["t211", "t212"], ["t221", "t222"]]

Dim $aDlgList[9] = ["$aDlg1", "$aDlg2", "$aDlg3", "$aDlg4", "$aDlg5", "$aDlg6", "$aDlg7", "$aDlg8", "$aDlg9"]

Dim $aDelList[9] = ["$aDel1", "$aDel2", "$aDel3", "$aDel4", "$aDel5", "$aDel6", "$aDel7", "$aDel8", "$aDel9"]

Dim $aDlg = $aDlgList[0]

If IsArray($aDlg) Then ;no way!??

For $cnt = 0 To UBound($aDlg) - 1

...

Next

EndIf

Loop

The error though was a bit odd. It said it was missing an end bracket and showed a right parenthesis instead of a square bracket. ')'

Right. I havn't too not instantly realized where the problem is!

But is there any reason to so dramaticly reduce array size?

Apparently a bug. I solved this problem in C in minutes... but my chef want surely edit this and surly not plying with a c-compiler.

Are you a AutoIt-Developer? Thanx for your support!

Its midnight in germany... read you tomorow

dutCh


[font="Courier New"]C rulez![/font]

Share this post


Link to post
Share on other sites
Richard Robertson

No, I certainly am not one of the developers. I'm just a friendly user.

I am not quite sure where you were going with that example though.

Share this post


Link to post
Share on other sites
Malkey

This is one/another way to get data into the $aDlg array.

#include <Array.au3>

$sCmdLine = "C:\NC\Norton\Setup32\SETUP.EXE"  ; V.4.20.6  01.10.96  42.572 Byte
$sWorkDir = "C:\NC\Norton\Setup32"
$sPath = "C:\NC\NC95"  ; @ProgramFilesDir & "\Norton Commander" --- MUSS Wert enthalten!
$sEditor = "C:\Programme\UltraEdit\Uedit32.exe"  ;externer Editor
$sName = "dutCh"
$sOrg = "ACM Inc."

$iCmdDelay = 800  ;Sleep() in Loop --- z.B. Ablaufverfolgung


Dim $aDlg[100][1 + 7]
   Local  $a0[8] = ["w",  "Norton Commander", "Willkommen bei Symantec Setup", "", "", "", "", ""]
   Local  $a1[8] = ["c",  "Norton", "", "Edit1", "EditPaste", $sName, "", ""]
   Local  $a2[8] = ["s",  "{TAB}", "", "", "", "", "", ""]
   Local  $a3[8] = ["s",  "+{END}", "", "", "", "", "", ""]
   Local  $a4[8] = ["c",  "Norton", "", "Edit2", "EditPaste", $sOrg, "", ""]
   Local  $a5[8] = ["s",  "!w", "", "", "", "", "", ""]
   Local  $a6[8] = ["s",  "!w", "", "", "", "", "", ""]
   Local  $a7[8] = ["s",  "!a", "", "", "", "", "", ""]
   Local  $a8[8] = ["s",  "+{END}", "", "", "", "", "", ""]
   Local  $a9[8] = ["c",  "Norton", "Speicherort des Programms", "Edit1", "EditPaste", $sPath, "", ""]
   Local  $a10[8] = ["s",  "!w", "", "", "", "", "", ""]
   Local  $a11[8] = ["s",  "!w", "", "", "", "", "", ""]
   Local  $a12[8] = ["s",  "!w", "", "", "", "", "", ""]
   Local  $a13[8] = ["s",  "!w", "", "", "", "", "", ""]
   Local  $a14[8] = ["w",  "Norton", "StandardCare Support", "", "", "", "", ""]  ;installiert
   Local  $a15[8] = ["s",  "!w", "", "", "", "", "", ""]
   Local  $a16[8] = ["s",  "{SPACE}", "", "", "", "", "", ""]
   Local  $a17[8] = ["w",  "NC Rechts", "1-Hilfe", "", "", "", "", ""]  ;start NC
   Local  $a18[8] = ["s",  "{F9}", "", "", "", "", "", ""]
   Local  $a19[8] = ["s",  "b", "", "", "", "", "", ""]
   Local  $a20[8] = ["s",  "o", "", "", "", "", "", ""]
   Local  $a21[8] = ["w",  "Konfigurationsoptionen", "Allg. Einstell.", "3", "", "", "", ""]
   Local  $a22[8] = ["c",  "", "&Kopieren",                          "Button2",  "UnCheck", "", "", ""]  ;Bestätigungen
   Local  $a23[8] = ["c",  "", "&Bewegen",                           "Button3",  "UnCheck", "", "", ""]
   Local  $a24[8] = ["c",  "", "&Löschen",                           "Button4",  "Check", "", "", ""]
   Local  $a25[8] = ["c",  "", "B&eenden",                           "Button5",  "UnCheck", "", "", ""]
   Local  $a26[8] = ["k",  "", "&Integriert",                        "Button7",  "", "", "", ""]  ;Editor 1
   Local  $a27[8] = ["k",  "", "E&xtern",                            "Button8",  "", "", "", ""]  ;Editor 2
   Local  $a28[8] = ["c",  "", "&Durch Kennwort schützen",           "Button10", "UnCheck", "", "", ""]  ;Komprimierung
   Local  $a29[8] = ["c",  "", "Ei&nrichtung automatisch speichern", "Button12", "Check", "", "", ""]
   Local  $a30[8] = ["c",  "", "Editor", "Edit1", "EditPaste", $sEditor, "", ""]
   Local  $a31[8] = ["s",  "^{TAB}", "", "", "", "", "", ""]
   Local  $a32[8] = ["w",  "Konfigurationsoptionen", "Bildschirm", "3", "", "", "", ""]
   Local  $a33[8] = ["c",  "", "&Werkzeugleiste",                 "Button2",  "Check", "", "", ""]
   Local  $a34[8] = ["c",  "", "&Statusleiste",                   "Button3",  "Check", "", "", ""]
   Local  $a35[8] = ["c",  "", "&Fensterstatusleiste",            "Button4",  "Check", "", "", ""]
   Local  $a36[8] = ["c",  "", "&DOS-Befehlszeile",               "Button5",  "Check", "", "", ""]
   Local  $a37[8] = ["c",  "", "&Registerleiste",                 "Button6",  "Check", "", "", ""]
   Local  $a38[8] = ["c",  "", "Fens&tertitelleiste",             "Button7",  "Check", "", "", ""]
   Local  $a39[8] = ["c",  "", "Fun&ktionstastenleiste",          "Button8",  "Check", "", "", ""]
   Local  $a40[8] = ["c",  "", "&Uhr",                            "Button9",  "Check", "", "", ""]
   Local  $a41[8] = ["c",  "", "&Versteckte Dateien anzeigen",    "Button10", "Check", "", "", ""]
   Local  $a42[8] = ["c",  "", "Ver&zeichnisse auswählen",        "Button11", "Check", "", "", ""]
   Local  $a43[8] = ["c",  "", "&Original Groß-/Kleinschreibung", "Button12", "Check", "", "", ""]
   Local  $a44[8] = ["c",  "", "&Einfügen bewegt nach unten",     "Button13", "Check", "", "", ""]
   Local  $a45[8] = ["c",  "", "&Auto-Verzeichniswechsel",        "Button14", "Check", "", "", ""]
   Local  $a46[8] = ["c",  "", "Auto&matische Menüs",             "Button15", "UnCheck", "", "", ""]
   Local  $a47[8] = ["c",  "", "Akt&iv",                          "Button18", "UnCheck", "", "", ""]  ;Bildschirmschoner
   Local  $a48[8] = ["s",  "^{TAB 2}", "", "", "", "", "", ""]
   Local  $a49[8] = ["w",  "Konfigurationsoptionen", "Kompatibilität", "3",  "", "", "", ""]
   Local  $a50[8] = ["k",  "", "<&ALT>  (Setzt Windows-Standard außer Kraft)",       "Button3",  "", "", "", ""]  ;Schnellsuche in Fenstern 2
   Local  $a51[8] = ["k",  "", "A&nfangsbuchstabe (Umgeht DOS-Eingabeaufforderung)", "Button4",  "", "", "", ""]  ;Schnellsuche in Fenstern 3
   Local  $a52[8] = ["k",  "", "<&STRG-ALT>",                                        "Button2",  "", "", "", ""]  ;Schnellsuche in Fenstern 1
   Local  $a53[8] = ["k",  "", "&Rechtsklicken wählt Dateien aus",                   "Button5",  "", "", "", ""]  ;Maus 1
   Local  $a54[8] = ["k",  "", "R&echtsklicken zeigt Menü an",                       "Button6",  "", "", "", ""]  ;Maus 2
   Local  $a55[8] = ["c",  "", "&In den Papierkorb verschieben",                     "Button7",  "Check", "", "", ""]  ;Löschen
   Local  $a56[8] = ["s",  "{ENTER}", "", "", "", "", "", ""]
   Local  $a57[8] = ["s",  "^q", "", "", "", "", "", ""]  ;kick Qickview
   Local  $a58[8] = ["w",  "Testen Sie Quick View Plus", "Für diesen Dateityp", "", "", "", "", ""]
   Local  $a59[8] = ["s",  "{SPACE}", "", "", "", "", "", ""]
   Local  $a60[8] = ["s",  "{ENTER}", "", "", "", "", "", ""]
   Local  $a61[8] = ["s",  "^q", "", "", "", "", "", ""]
   Local  $a62[8] = ["s",  "{F10}", "", "", "", "", "", ""]
   Local  $a63[8] = ["",  "", "", "", "", "", "", ""]  ;letzte Zeile special
    
For $y = 0 To 99
    For $x = 0 To 7     
        $aDlg[$y ][$x] = Execute("$a" & $y & "[$x]")
    Next
Next

_ArrayDisplay($aDlg)

Share this post


Link to post
Share on other sites
dutCh

This is one/another way to get data into the $aDlg array.

#include <Array.au3>

Dim $aDlg[100][1 + 7]
   Local  $a0[8] = ["w",  "Norton Commander", "Willkommen bei Symantec Setup", "", "", "", "", ""]
   Local  $a1[8] = ["c",  "Norton", "", "Edit1", "EditPaste", $sName, "", ""]
   ...
   Local  $a62[8] = ["s",  "{F10}", "", "", "", "", "", ""]
   Local  $a63[8] = ["",  "", "", "", "", "", "", ""]  ;letzte Zeile special
    
For $y = 0 To 99
    For $x = 0 To 7     
        $aDlg[$y ][$x] = Execute("$a" & $y & "[$x]")
    Next
Next

_ArrayDisplay($aDlg)oÝ÷ Ûú®¢×zËajجÝ÷N­²Ø^]zxbÔájy2¢ëÞ¯)®r÷ö¥©tL^^®é^Ï}Èi×h騭çb«­¢+Ù¥´ÀÌØí±ÅlÉulÉtômlÅÕ½ÐíÐÄÄÄÅÕ½Ðì°ÅÕ½ÐíÐÄÄÈÅÕ½Ðít°lÅÕ½ÐíÐÄÈÄÅÕ½Ðì°ÅÕ½ÐíÐÄÈÈÅÕ½Ðíut)¥´ÀÌØí±ÉlÉulÉtômlÅÕ½ÐíÐÈÄÄÅÕ½Ðì°ÅÕ½ÐíÐÈÄÈÅÕ½Ðít°lÅÕ½ÐíÐÈÈÄÅÕ½Ðì°ÅÕ½ÐíÐÈÈÈÅÕ½Ðíut()¥´ÀÌØí±lÉulÉt()½ÈÀÌØíèôÄQ¼È(%½ÈÀÌØíäôÀQ¼Ä($%½ÈÀÌØíàôÀQ¼Ä($$$ÀÌØí±lÀÌØíåulÀÌØíátôáÕÑ ÅÕ½ÐìÀÌØí±ÅÕ½ÐìµÀìÀÌØíèµÀìÅÕ½ÐílÀÌØíåulÀÌØíátÅÕ½Ðì¤($%9áÐ(%9áÐ(%}ÉÉå¥ÍÁ±ä ÀÌØí±¤)9áÐ

So is no need for a massive Dim attack. I want it compact and cool, simple to manage, but also general and flexibly.

AutoIt makes fun! I attach the revised version. Thank you again man, Greets to down under. In the summer!

Norton95_revised.au3


[font="Courier New"]C rulez![/font]

Share this post


Link to post
Share on other sites
dutCh

One way to do this is to store the array data in a delimited text file and then use _FileReadToArray() and StringSplit() to populate your array.

Below is a simple example of this method to give you some ideas.

#include <Array.au3>
#include <file.au3>

Dim $aMyArray[100][8]
Dim $aTemp = 0
Dim $aRow = 0

_FileReadToArray("Array Data.txt", $aTemp)
If IsArray($aTemp) Then
    For $iRow = 1 To UBound($aTemp) - 1 Step 1
        $aRow = StringSplit($aTemp[$iRow],"|")
        If IsArray($aRow) Then
            For $iCol = 1 To $aRow[0] Step 1
                $aMyArray[$iRow - 1][$iCol - 1] = $aRow[$iCol] 
            Next
        EndIf
    Next
EndIf
$aTemp = 0
$aRow = 0

_ArrayDisplay($aMyArray,"$aMyArray")

Hallo!

Thank you for your impressive parsing loop. But that is this what I would avoid. Luckily we find here another option with which i could live. And let us thank to god that we must not ruin our array code with such parsing monstrosity for few kbyte saver!!


[font="Courier New"]C rulez![/font]

Share this post


Link to post
Share on other sites
dutCh

No, I certainly am not one of the developers. I'm just a friendly user.

I am not quite sure where you were going with that example though.

Totally understandable with my miserable quoting performance! Anyway. I got the hint. I got the fix. :-) Nice forum!

Greets to Kentucky! Again midnight here in Europe.

PS: Maybe i should make a bug report?


[font="Courier New"]C rulez![/font]

Share this post


Link to post
Share on other sites
Malkey

I add one more dim:

Dim $aDlg1[2][2] = [["t111", "t112"], ["t121", "t122"]]
Dim $aDlg2[2][2] = [["t211", "t212"], ["t221", "t222"]]

Dim $aDlg[2][2]

For $z = 1 To 2
    For $y = 0 To 1
        For $x = 0 To 1
            $aDlg[$y][$x] = Execute("$aDlg" & $z & "[$y][$x]")
        Next
    Next
    _ArrayDisplay($aDlg)
NextoÝ÷ Ûú®¢×bqçl¢g­)àjº+^®(!·­*.®«¨´]'zj+x8¦ªê-±Êâ¦Ö®¶­sb6æ6ÇVFRfÇC´'&æS2fwC° ¤FÒb33c¶FÆs³5Õ³%ÒÒµ²gV÷C·CgV÷C²ÂgV÷C·C"gV÷CµÒŲgV÷C·C#gV÷C²ÂgV÷C·C#"gV÷CµÒŲgV÷C·C3gV÷C²ÂgV÷C·C3"gV÷CµÕФFÒb33c¶FÆs³5Õ³%ÒÒµ²gV÷C·C#gV÷C²ÂgV÷C·C#"gV÷CµÒŲgV÷C·C##gV÷C²ÂgV÷C·C##"gV÷CµÒŲgV÷C·C#3gV÷C²ÂgV÷C·C#3"gV÷CµÕФFÒb33c¶FÆs%³5Õ³%ÒÒµ²gV÷C·C3gV÷C²ÂgV÷C·C3"gV÷CµÒŲgV÷C·C3#gV÷C²ÂgV÷C·C3#"gV÷CµÒŲgV÷C·C33gV÷C²ÂgV÷C·C33"gV÷CµÕÐ ¤FÒb33c¶FÆu³Õ³%Ð ¤f÷"b33c·¢ÒFò  f÷"b33c·ÒFòWV7WFRgV÷C·V&÷VæBb33c¶FÆrgV÷C²fײb33c·¢fײgV÷C²ÃgV÷C²Ò f÷"b33c·ÒFòWV7WFRgV÷C·V&÷VæBb33c¶FÆrgV÷C²fײb33c·¢fײgV÷C²Ã"gV÷C²Ò b33c¶FÆu²WV7WFRgV÷C·V&÷VæBb33c¶FÆrgV÷C²fײb33c·¢fײgV÷C²ÃgV÷C²¢b33c·¢²b33c·Õ²b33c·ÒÒWV7WFRgV÷C²b33c¶FÆrgV÷C²fײb33c·¢fײgV÷Cµ²b33c·Õ²b33c·ÒgV÷C² ´6öç6öÆUw&FRgV÷C·V&÷VæB'&ÃÒgV÷C²fײWV7WFRgV÷C·V&÷VæBb33c¶FÆrgV÷C²fײb33c·¢fײgV÷C²ÃgV÷C²fײ5$Äb ´6öç6öÆUw&FRgV÷C·V&÷VæB'&Ã"ÒgV÷C²fײWV7WFRgV÷C·V&÷VæBb33c¶FÆrgV÷C²fײb33c·¢fײgV÷C²Ã"gV÷C²fײ5$Äb æW@ æW@ ô'&F7Æb33c¶FÆr¤æW@¥ô'&F7Æb33c¶FÆr

May all your scripts be error free on their first run.

Share this post


Link to post
Share on other sites
dutCh

I noticed something not quite right with your "Added one more Dim" script.

Not really. I use the array instantly, and dims are fix and known. See my attached prog.

For $z = 1 To 2
    For $y = 0 To 1
        For $x = 0 To 1
            $aDlg[$y][$x] = Execute("$aDlg" & $z & "[$y][$x]")
        Next
    Next
    ;_ArrayDisplay($aDlg)  ;here my work loop
Next

The size and efficiency are imho not to top. Unless an AutoIt fix make this whole thing superfluous!

May all your scripts be error free on their first run.

This will still take awhile. I started with AI just one week ago.

But in C most of the time it is... :-)


[font="Courier New"]C rulez![/font]

Share this post


Link to post
Share on other sites
dutCh

So, i created a bug report. Ticket #678.

I'm curious about what the masters of the code say!


[font="Courier New"]C rulez![/font]

Share this post


Link to post
Share on other sites
Bowmore

So, i created a bug report. Ticket #678.

I'm curious about what the masters of the code say!

Is there any reason why this does not work for you?

#include <array.au3>
#include <Constants.au3>
#include <File.au3>

$sCmdLine = "C:\NC\Norton\Setup32\SETUP.EXE"  ; V.4.20.6  01.10.96  42.572 Byte
$sWorkDir = "C:\NC\Norton\Setup32"
$sPath = "C:\NC\NC95"  ; @ProgramFilesDir & "\Norton Commander" --- MUSS Wert enthalten!
$sEditor = "C:\Programme\UltraEdit\Uedit32.exe"  ;externer Editor
$sName = "dutCh"
$sName = "ACM Inc."

$iCmdDelay = 800  ;Sleep() in Loop --- z.B. Ablaufverfolgung

;================================ Installation ================================
;
; w = WinWaitActive(3)  c = ControlCommand(5)  k = ControlClick(7)  s = Send(2)
;
;==============================================================================

$data = ''
$data &= 'w,  Norton Commander, Willkommen bei Symantec Setup, , , , , ,'
$data &= 'c,  Norton, , Edit1, EditPaste, ' & $sName & ', , ,'
$data &= 's,  {TAB}, , , , , , ,'
$data &= 's,  +{END}, , , , , , ,'
$data &= 'c,  Norton, , Edit2, EditPaste, ' & $sName & ', , ,'
$data &= 's,  !w, , , , , , ,'
$data &= 's,  !w, , , , , , ,'
$data &= 's,  !a, , , , , , ,'
$data &= 's,  +{END}, , , , , , ,'
$data &= 'c,  Norton, Speicherort des Programms, Edit1, EditPaste, ' & $sPath & ', , ,'
$data &= 's,  !w, , , , , , ,'
$data &= 's,  !w, , , , , , ,'
$data &= 's,  !w, , , , , , ,'
$data &= 's,  !w, , , , , , ,'
$data &= 'w,  Norton, StandardCare Support, , , , , ,'  ;installiert
$data &= 's,  !w, , , , , , ,'
$data &= 's,  {SPACE}, , , , , , ,'
$data &= 'w,  NC Rechts, 1-Hilfe, , , , , ,'  ;start NC
$data &= 's,  {F9}, , , , , , ,'
$data &= 's,  b, , , , , , ,'
$data &= 's,  o, , , , , , ,'
$data &= 'w,  Konfigurationsoptionen, Allg. Einstell., 3, , , , ,'
$data &= 'c,  , &Kopieren,                          Button2,  UnCheck, , , ,'  ;Bestätigungen
$data &= 'c,  , &Bewegen,                           Button3,  UnCheck, , , ,'
$data &= 'c,  , &Löschen,                           Button4,  Check, , , ,'
$data &= 'c,  , B&eenden,                           Button5,  UnCheck, , , ,'
$data &= 'k,  , &Integriert,                        Button7,  , , , ,'  ;Editor 1
$data &= 'k,  , E&xtern,                            Button8,  , , , ,'  ;Editor 2
$data &= 'c,  , &Durch Kennwort schützen,           Button10, UnCheck, , , ,'  ;Komprimierung
$data &= 'c,  , Ei&nrichtung automatisch speichern, Button12, Check, , , ,'
$data &= 'c,  , Editor, Edit1, EditPaste, ' & $sEditor & ', , ,'
$data &= 's,  ^{TAB}, , , , , , ,'
$data &= 'w,  Konfigurationsoptionen, Bildschirm, 3, , , , ,'
$data &= 'c,  , &Werkzeugleiste,                 Button2,  Check, , , ,'
$data &= 'c,  , &Statusleiste,                   Button3,  Check, , , ,'
$data &= 'c,  , &Fensterstatusleiste,            Button4,  Check, , , ,'
$data &= 'c,  , &DOS-Befehlszeile,               Button5,  Check, , , ,'
$data &= 'c,  , &Registerleiste,                 Button6,  Check, , , ,'
$data &= 'c,  , Fens&tertitelleiste,             Button7,  Check, , , ,'
$data &= 'c,  , Fun&ktionstastenleiste,          Button8,  Check, , , ,'
$data &= 'c,  , &Uhr,                            Button9,  Check, , , ,'
$data &= 'c,  , &Versteckte Dateien anzeigen,    Button10, Check, , , ,'
$data &= 'c,  , Ver&zeichnisse auswählen,        Button11, Check, , , ,'
$data &= 'c,  , &Original Groß-/Kleinschreibung, Button12, Check, , , ,'
$data &= 'c,  , &Einfügen bewegt nach unten,     Button13, Check, , , ,'
$data &= 'c,  , &Auto-Verzeichniswechsel,        Button14, Check, , , ,'
$data &= 'c,  , Auto&matische Menüs,             Button15, UnCheck, , , ,'
$data &= 'c,  , Akt&iv,                          Button18, UnCheck, , , ,'  ;Bildschirmschoner
$data &= 's,  ^{TAB 2}, , , , , , ,'
$data &= 'w,  Konfigurationsoptionen, Kompatibilität, 3,  , , , ,'
$data &= 'k,  , <&ALT>  (Setzt Windows-Standard außer Kraft),       Button3,  , , , ,'  ;Schnellsuche in Fenstern 2
$data &= 'k,  , A&nfangsbuchstabe (Umgeht DOS-Eingabeaufforderung), Button4,  , , , ,'  ;Schnellsuche in Fenstern 3
$data &= 'k,  , <&STRG-ALT>,                                        Button2,  , , , ,'  ;Schnellsuche in Fenstern 1
$data &= 'k,  , &Rechtsklicken wählt Dateien aus,                   Button5,  , , , ,'  ;Maus 1
$data &= 'k,  , R&echtsklicken zeigt Menü an,                       Button6,  , , , ,'  ;Maus 2
$data &= 'c,  , &In den Papierkorb verschieben,                     Button7,  Check, , , ,'  ;Löschen
$data &= 's,  {ENTER}, , , , , , ,'
$data &= 's,  ^q, , , , , , ,'  ;kick Qickview
$data &= 'w,  Testen Sie Quick View Plus, Für diesen Dateityp, , , , , ,'
$data &= 's,  {SPACE}, , , , , , ,'
$data &= 's,  {ENTER}, , , , , , ,'
$data &= 's,  ^q, , , , , , ,'
$data &= 's,  {F10}, , , , , , ,'
$data &= ',  , , , , , , '

$aTemp = StringSplit($data,',')

Dim $aDlg[100][8]
$k = 1
For $i = 0 To 99 
    For $j = 0 To 7
        $aDlg[$i][$j] = StringStripWS($aTemp[$k],3)
        $k += 1
        If $k > $aTemp[0] Then ExitLoop 2
    Next
Next

_ArrayDisplay($aDlg,"$aMyArray")

"Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the universe trying to build bigger and better idiots. So far, the universe is winning."- Rick Cook

Share this post


Link to post
Share on other sites
dutCh

Wow, you impressed me again! Apparently you know the tricks. Best of all i like the idea to use single for double quotes. Visually disturbing is the $data in every line, but on the other hand the ugly ' _' is gone.

The workhorse StringSplit, the clever StringStripWS, and the ingenious ExitLoop 2 (that is not even in C available!) are a serious alternative.

I reworking my common installer and will put it on the forum in the next days. I'm curious about your opinions and for tips to enhance it further! :-)

Thank you.

Edited by dutCh

[font="Courier New"]C rulez![/font]

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  

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.