Jump to content

Recommended Posts

Posted

Creates an array and assigns values to the array

Example:

Dim $Array[3]
Global $array[2] = [1, 2]
for $x=0 To UBound($array) -1
    MsgBox(0,$x,$array[$x])
Next

<{POST_SNAPBACK}>

ty for the reply , also why do i get an error?
HKTunes:Softpedia | GoogleCodeLyricToy:Softpedia | GoogleCodeRCTunes:Softpedia | GoogleCodeMichtaToolsProgrammer n. - An ingenious device that turns caffeine into code.
Posted

Are you using the latest beta? It was only introduced a few beta versions ago.

David Nuttall
Nuttall Computer Consulting

An Aquarius born during the Age of Aquarius

AutoIt allows me to re-invent the wheel so much faster.

I'm off to write a wizard, a wonderful wizard of odd...

Posted (edited)

Are you using the latest beta?  It was only introduced a few beta versions ago.

<{POST_SNAPBACK}>

No. I was using .54. Will update to .55 and see if that helps.

ty for the reply.

Edited by SolidSnake
HKTunes:Softpedia | GoogleCodeLyricToy:Softpedia | GoogleCodeRCTunes:Softpedia | GoogleCodeMichtaToolsProgrammer n. - An ingenious device that turns caffeine into code.
Posted (edited)

just tried this and it works.

Dim $Array[3]
Global $array[2] = [1, 2]
for $x=0 To UBound($array) -1
    MsgBox(0,$x,$array[$x])
Next

I am still not exactly clear on what it does though. It is supposed to be like _ArrayCreate (). Right?. If so then why does this array not display?

#include <Array.au3>
Global $Array = [1, 2]
_ArrayDisplay($Array, "")
Edited by SolidSnake
HKTunes:Softpedia | GoogleCodeLyricToy:Softpedia | GoogleCodeRCTunes:Softpedia | GoogleCodeMichtaToolsProgrammer n. - An ingenious device that turns caffeine into code.
Posted (edited)

just tried this and it works.

Dim $Array[3]
Global $array[2] = [1, 2]
for $x=0 To UBound($array) -1
    MsgBox(0,$x,$array[$x])
Next

I am still not exactly clear on what it does though. It is supposed to be like _ArrayCreate (). Right?. If so then why does this array not display?

#include <Array.au3>
Global $Array = [1, 2]
_ArrayDisplay($Array, "")

<{POST_SNAPBACK}>

Does that even run?

Should give syntax error because it isn't an array that your trying to assign values to.

Lets see if this example makes it any clearer for you.

#include <Array.au3>
Global $Array[2] = ["Joe", "Bob"]
_ArrayDisplay($Array, "")
Edited by gafrost

SciTE for AutoItDirections for Submitting Standard UDFs

 

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

 

Posted

Does that even run?

Should give syntax error because it isn't an array that your trying to assign values to.

Lets see if this example makes it any clearer for you.

#include <Array.au3>
Global $Array[2] = ["Joe", "Bob"]
_ArrayDisplay($Array, "")

<{POST_SNAPBACK}>

So that would make $Array[0]="Joe" and $Array[1]="Bob".

Ty. I think i get it now. :)

HKTunes:Softpedia | GoogleCodeLyricToy:Softpedia | GoogleCodeRCTunes:Softpedia | GoogleCodeMichtaToolsProgrammer n. - An ingenious device that turns caffeine into code.
Posted

Well, programming is hard. When you fix something, you break somthing else. Let's see if this works better - v1.43.

blub

Posted

Here's the last version generated from the 3.1.1.55 beta docs: http://www.autoitscript.com/fileman/users/jdeb/beta/au3check.dat

-or-

Download the latest SciTe4Au3Upd.exe which contains  definition files for all included tools.

<{POST_SNAPBACK}>

where are the definitions for PSPad?
Posted

Found you another bug tylo.

Global Const $var = "value"
Test1($var)

Func Test1(Const ByRef $_var)
    Test2($_var)
EndFunc

Func Test2(Const ByRef $__var)
    ConsoleWrite($__var & @CR)
EndFunc

AutoIt3 Syntax Checker v1.43  Copyright © Tylo 2005

New AutoIt v3 Script.au3(4,30) : ERROR: Test1() previously called with Const/expression on ByRef param(s).

Func Test1(Const ByRef $_var)

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^

New AutoIt v3 Script.au3(2,11) : REF: first call to Test1().

Test1($var)

~~~~~~~~~~^

New AutoIt v3 Script.au3(8,31) : ERROR: Test2() previously called with Const/expression on ByRef param(s).

Func Test2(Const ByRef $__var)

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^

New AutoIt v3 Script.au3(5,13) : REF: first call to Test2().

Test2($_var)

~~~~~~~~~~~^

New AutoIt v3 Script.au3 - 2 error(s), 0 warning(s)

Posted

Tylo,

Regarding, Au3Check.dat.

When you get a chance,

TCPStartup

TCPShutdown

UDPStartup

UDPShutdown

Currently all have Zero parameters

Thanks!

Bill

Posted

Tylo,

Regarding, Au3Check.dat.

When you get a chance,

TCPStartup

TCPShutdown

UDPStartup

UDPShutdown

Currently all have Zero parameters

Thanks!

Bill

<{POST_SNAPBACK}>

There aren't any parameters for those..........
[u]Do more with pre-existing apps![/u]ANYGUIv2.8
  • Developers
Posted

v1.45. Added 'Default' keyword support, and updated .dat file.

<{POST_SNAPBACK}>

Attached an updated version of the DAT file with the following updates:

Added: !Execute 1 1

Updated: !UDPSend 4 4 to !UDPSend 2 2

:)

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

  • 2 weeks later...
Posted

Tylo,

Au3Check is great!

Is it possible for you to add an option/switch that would change the output format from (line number,Char) to just (Line number)?

For example:

New AutoIt v3 Script.au3(4,30) : ERROR: Te

would become

New AutoIt v3 Script.au3(4) : ERROR: Te

Thanks

“Give a man a script; you have helped him for today. Teach a man to script; and you will not have to hear him whine for help.”AutoIt4UE - Custom AutoIt toolbar and wordfile for UltraEdit/UEStudio users.AutoIt Graphical Debugger - A graphical debugger for AutoIt.SimMetrics COM Wrapper - Calculate string similarity.

Posted

Tylo,

Au3Check is great!

Is it possible for you to add an option/switch that would change the output format from (line number,Char) to just (Line number)?

For example:

New AutoIt v3 Script.au3(4,30) : ERROR: Te

would become

New AutoIt v3 Script.au3(4) : ERROR: Te

Thanks

<{POST_SNAPBACK}>

Why would we want that? It tells you where to look for the error in the line! This seems like a step backwards to me.
Posted

Why would we want that?  It tells you where to look for the error in the line!  This seems like a step backwards to me.

<{POST_SNAPBACK}>

That's why I asked for it to an option :)

I use Ultraedit to run the syntax check and it will parses the au3check file's outputs and can take you directly to the line with the error. However it does not work because of the char location in the brackets.

“Give a man a script; you have helped him for today. Teach a man to script; and you will not have to hear him whine for help.”AutoIt4UE - Custom AutoIt toolbar and wordfile for UltraEdit/UEStudio users.AutoIt Graphical Debugger - A graphical debugger for AutoIt.SimMetrics COM Wrapper - Calculate string similarity.

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
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...