Announcement

Collapse
No announcement yet.

cancel error

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • jassing
    replied
    Originally posted by RizlaUK View Post
    sounds nice, im in the heart of this concreate jungle called "London", the place everyone loves to visit, but hates to live in....the only island round here is a traffic island, lol
    I used to live in San Francisco and San Diego -- I've realized that I don't like crowds -- I'm bummed someone built a house boarding my lot.. I don't know how you do it --- but then again; England is an island ;-)



    Originally posted by RizlaUK View Post
    usually the case,time spent reading can save time spent posting.......
    It's always hard to balance the desire to help; and the need not to do someone elses work 100% -- to learn; you have to want to understand; but sometimes, language is also very hard barrier....

    Leave a comment:


  • RizlaUK
    replied
    I'm on the west coast of the USA on a small island....
    sounds nice, im in the heart of this concreate jungle called "London", the place everyone loves to visit, but hates to live in....the only island round here is a traffic island, lol

    it does work; you're just not understanding the concepts.
    usually the case,time spent reading can save time spent posting.......

    Leave a comment:


  • jassing
    replied
    Originally posted by rexzooly View Post
    woow there feller i didn't mean anything but AMS makes lua much more
    easyer to handle ues i agree its robust i love it so much i moved all my learing
    from VB,C++ and all that side to Lua as i liked what i saw.

    please don't take what i said in anyway asgest lua
    Must be a language thing then; becuase I don't understand your comment at all then. Sorry.
    -josh

    Leave a comment:


  • jassing
    replied
    google:

    put the function declaration in "global functions" or a script file.
    You can't put a function declaration inline with code.

    Then you need to call it so you can split it.

    it does work; you're just not understanding the concepts.

    Leave a comment:


  • GoOgLe
    replied
    string splitpath help

    it doesnt split the path !!

    Code:
    myDocsFolder = Shell.GetFolder(SHF_MYDOCUMENTS);
    Folder.Create(myDocsFolder.."\\Addons");
    
    tblMenu = Application.GetMenu();
    local nNewitem = Table.Count(tblMenu)+1;
    tblMenu[nNewitem] ={};
    tblMenu[nNewitem].Text = "&Addons";
    tblMenu[nNewitem].ID = 1000;
    tblMenu[nNewitem].Checked = false;
    tblMenu[nNewitem].Enabled = true;
    tblMenu[nNewitem].SubMenu = {};
    
    local tFiles = File.Find(myDocsFolder.."\\Addons", "*.exe");
    function File.GetName(sFile) 
    return String.SplitPath(sFile).Filename..String.SplitPath(sFile).Extension 
    end
    if (tFiles) then
    local x = 0;
    for x = 1,Table.Count(tFiles) do
    	tblMenu[nNewitem].SubMenu[x] = {};
    	tblMenu[nNewitem].SubMenu[x].Text = tFiles[x];
    	tblMenu[nNewitem].SubMenu[x].ID = 1000+x;
    	tblMenu[nNewitem].SubMenu[x].Checked = false;
    	tblMenu[nNewitem].SubMenu[x].Enabled = true;
    end
    
    Application.SetMenu(tblMenu);
    
    else
    end

    Leave a comment:


  • rexzooly
    replied
    Originally posted by jassing View Post
    What do you mean "so something had to be done to make the functions easyer maybe"?

    AMS isn't simple by any means -- it's actually a fairly robust RAD environment -- not full blown applications; but it's definately strong.

    LUA wouldn't have been my 1st choice; but it just adds to the strength of the product -- lua is flexible and robust.

    I don't get (or understand) your point.
    woow there feller i didn't mean anything but AMS makes lua much more
    easyer to handle ues i agree its robust i love it so much i moved all my learing
    from VB,C++ and all that side to Lua as i liked what i saw.

    please don't take what i said in anyway asgest lua

    Leave a comment:


  • jassing
    replied
    Originally posted by screwed over View Post
    i'm in england. i know what ya mean by that, i've once completley overwritten the built in label functions in apms before. i dont even know how i did that but it was a pain, had to rewrite over half of my scripts to fix it.
    I'm on the west coast of the USA on a small island....

    Cheers
    -josh

    Leave a comment:


  • jassing
    replied
    Originally posted by rexzooly View Post
    i think its becusae AMS use custom lables to start with maybe i am wrong
    but AMS is way simpler then lua its self so something had to be done to make
    the fuctions easyer maybe? i don't know just going out on a wim here.
    What do you mean "so something had to be done to make the functions easyer maybe"?

    AMS isn't simple by any means -- it's actually a fairly robust RAD environment -- not full blown applications; but it's definately strong.

    LUA wouldn't have been my 1st choice; but it just adds to the strength of the product -- lua is flexible and robust.

    I don't get (or understand) your point.

    Leave a comment:


  • rexzooly
    replied
    Originally posted by screwed over View Post
    i'm in england. i know what ya mean by that, i've once completley overwritten the built in label functions in apms before. i dont even know how i did that but it was a pain, had to rewrite over half of my scripts to fix it.
    i think its becusae AMS use custom lables to start with maybe i am wrong
    but AMS is way simpler then lua its self so something had to be done to make
    the fuctions easyer maybe? i don't know just going out on a wim here.

    Leave a comment:


  • screwed over
    replied
    i'm in england. i know what ya mean by that, i've once completley overwritten the built in label functions in apms before. i dont even know how i did that but it was a pain, had to rewrite over half of my scripts to fix it.

    Leave a comment:


  • jassing
    replied
    Originally posted by screwed over View Post
    was it? its like 1 in the morning so im not really paying attention.
    yea; I hear ya! Where ya located?

    Originally posted by screwed over View Post
    either way, it doesnt overwrite the built in tables

    That was a good catch -- i was embarassed that I didn't... I spent a day trying to fix a clients installer (I was not the original author) until I caught that they had overwritten the String object, indirectly...
    I wish the LUA Editor would say "Are you sure you want to overwrite the built in object?"

    I have, for my 64 bit registry support, intentionally overwriten the Registry object to avoid having to change references everywhere -- so being able to do it can be benificial...

    Leave a comment:


  • screwed over
    replied
    was it? its like 1 in the morning so im not really paying attention.

    either way, it doesnt overwrite the built in tables

    Leave a comment:


  • jassing
    replied
    Originally posted by screwed over View Post
    built in "File" tables like jassings. =P
    Screwed:
    That wasn't my code -- it was yours. ;-)

    All I pointed out was that you needed to address it as an array/table....

    Leave a comment:


  • screwed over
    replied
    Code:
    wFile = Dialog.FileBrowse(true, "Open HTML File", _DesktopFolder, "HTML Files (*.html, *.htm)|*.htm;*.html|", "", "html", false, false);
    if wFile[1] ~= "CANCEL" and wFile ~= nil then
        Web.LoadURL("Web1", wFile[1]);
    end
    this is pretty much the same as jassings but will only let the user select *.htm and *.html files. as well as checking incase you get a nil value (you shouldnt but it has happened to me before). plus it doesnt overwrite APMS built in "File" tables like jassings. =P
    Last edited by screwed over; 03-23-2008, 08:04 PM.

    Leave a comment:


  • Intrigued
    replied
    Ah, interesting Jassing. Something for us all to keep in mind, when performance becomes paramont.

    Thanks,

    Leave a comment:

Working...
X