View Full Version : AMS Action File Editor
RizlaUK
10-31-2008, 08:53 AM
inspired by a post in the forum, found here http://www.indigorose.com/forums/showpost.php?p=129257&postcount=130
i made this little app to open/view and edit action files for AMS.
AMS Action File Editor is a small tool that opens/views/edits and saves action xml files for AutoPlay Media Studio.
The action file is used by Indigo Rose to specify action information for the products’ built-in actions.
You can take a look at these files in the \Data\Actions subfolder of the product’s application folder.
This file is only for the use of the design environment.
It has no real affect on how your actions are called or what they do.
It is just there for the sake of the action wizard/editor and the intellisense editor when typing script.
Download (http://www.dnet-software.com/AMSApps/ AMS Action File Editor.exe)
C&C welcome, please report all bugs and suggestions for improvment
i have thoroughly tested this app and the xml files it produces and have tweeked the code to almost perfection, but there still might be a bug or 2 so please test any files you produce before you distrubte them.
Imagine Programming
10-31-2008, 09:21 AM
Nice work rizla!:) i thought you wanted to know that when you click the about option in the menu, the title of the about dialog is: MyDialog :)
holtgrewe
10-31-2008, 09:24 AM
Another nice addition.
Thanks RizlaUK.
RizlaUK
10-31-2008, 09:33 AM
Thanks guys, i missed a title, lol
i'll have an update soon, im adding some little tools, XML editor in text view so you can edit the file in tha app or in text mode, and a code template editor to edit the code templates xml file (right click in script editor "QuickScripts") to add your own code templates, i'll dig around the AMS xml and see if theres anything else i can add.
Imagine Programming
10-31-2008, 09:36 AM
Thanks guys, i missed a title, lol
i'll have an update soon, im adding some little tools, XML editor in text view so you can edit the file in tha app or in text mode, and a code template editor to edit the code templates xml file (right click in script editor "QuickScripts") to add your own code templates, i'll dig around the AMS xml and see if theres anything else i can add.
Great, nice work:) this will make plugin development a bit easier :D
Imagine Programming
10-31-2008, 09:45 AM
Hey rizla, i've made a few functions a while ago, maybe this will help you:)
not tested on 7.5 yet, but i guess it's not that hard to edit?
AMS_Objects = "Objects\\"
AMS_Actions = "Actions\\"
function GetAMS70Folder()
ClassID = Registry.GetValue(HKEY_CLASSES_ROOT, "AMS70.Document\\CLSID", "", true);
FullPath = Registry.GetValue(HKEY_CLASSES_ROOT, "CLSID\\"..ClassID.."\\LocalServer32", "", true);
sDrive=String.SplitPath(FullPath).Drive
sFolder=String.SplitPath(FullPath).Folder
return sDrive..sFolder
end
function GetAMS70Executable()
ClassID = Registry.GetValue(HKEY_CLASSES_ROOT, "AMS70.Document\\CLSID", "", true);
FullPath = Registry.GetValue(HKEY_CLASSES_ROOT, "CLSID\\"..ClassID.."\\LocalServer32", "", true);
return FullPath
end
function GetAMS70PluginsFolder()
return GetAMS70Folder().."Plugins\\"
end
function EnumeratePlugins(ObjectOrAction)
ToSearch=GetAMS70PluginsFolder()..ObjectOrAction;
FoundPlugins = Folder.Find(ToSearch, "*", false, nil);
return FoundPlugins
end
function FindLicense(Path)
Licenses = File.Find(Path, "*.lic", false, false, nil, nil);
if(Licenses==-1)or(Licenses==nil)then
Licenses = {}
Licenses[1]=-1
end
return Licenses[1]
end
Dermot
10-31-2008, 08:22 PM
Very handy tool, thank you. :yes
Centauri Soldier
11-01-2008, 12:49 AM
Nice job Rizla! This is a handy little tool. I can't wait to see what other ideas you have in mind for it.
Dermot
11-01-2008, 02:31 AM
When you set an argument as a combo, you can't seem to edit or remove combo items. You can only add items. The Remove button close the dialog.
RizlaUK
11-01-2008, 07:45 AM
lol, i dident write the code for remove button and i think i also overlooked the edit button, i dont know why, guess i was in a rush to publish it and overlooked a few things, i'll have that fixed today, iv changed a few things around to make a more generic tool for ams and removed the visual stuff from the GUI as i was just messing with the gradient plugin, i will post the new app in a new post as it will be a new tool.
Thanks for the feedback :yes
reteset
11-01-2008, 08:36 AM
very useful :yes
one thing
when <Type>string</Type>
<Default>"test"</Default> should be enclosed with quotes
if you add a auto help file (html pages) generation feature
you'll save my life :D
if you need a plugin or something similar for this program just PM me
i liked this , and i am willing to help improvement of this project
RizlaUK
11-01-2008, 10:19 AM
hi reteset, when setting default values i left it to the user to enclose text strings but i will make it check for quote tags and if missing then add them if the input is a string type (object name, filepath, etc)
AutoHelp, now theres a good idea, i dident think of that and im sure i can make that work, Thanks for the suggestions :yes
Imagine Programming
11-01-2008, 10:48 AM
This only get's better by the day :D
RizlaUK
11-07-2008, 06:35 PM
ok guys, heres an update (original link from first post)
all the above bugs have been fixed and lots has been added, the automatic help system is fully functional and there are a number of extra inputs related to the help file, all optional of course, the app help file has also been updated, read it if you are unsure about an input field. You only need to enter the bare data needed by the action editor to generate a help file but you can add as much or as little detail as you like
again, there may be a bug or 2, or there may not, test and report back so i can declear this app bug free and move onto some other useful tools :yes
Dermot
11-07-2008, 08:33 PM
Nice job. That help file generator is absolutely brilliant.
RizlaUK
11-08-2008, 09:25 AM
cheers Dermot, the final draft turned out alright, the power of some *borrowed* css and its looking quite good
Imagine Programming
11-08-2008, 09:54 AM
@Dermot, indeed, looks very neat. Thanks rizla:)
reteset
11-08-2008, 10:55 AM
perfect,
great job thanks :yes
RizlaUK
11-08-2008, 07:00 PM
some small bug fixes (current version v1.0.0.4)
(Fixed) a bug in generate html not asking for a file location, it was saving to test file "c:\myfile.html".
(Fixed) copy action not copying all fields.
(Fixed) copy argument not copy note fields.
(Fixed) a bug in string/number constraint dialog not clearing or loading right data.
(Fixed) last accessed file not showing in file dialogs, correct path but no file pre selected.
(Fixed) action description note html not being indented to right position.
Imagine Programming
11-10-2008, 09:40 AM
Wheeeeelp?! :wow
okay, it worked before, but AMS Action File Maker won't pop up anymore...
It stays in taskbar, even when i click the taskbarbuttons... What happend?:P
RizlaUK
11-10-2008, 09:53 AM
sounds like explorer has crashed, i used to get that a lot in xp, have you restarted ?
Imagine Programming
11-10-2008, 06:03 PM
No, i found the problem, for some reason it started on a location
-Window width and -window height, but with a shiny for loop and Window.SetPos i have reset it's position. I'm all happy again:)
Centauri Soldier
11-11-2008, 11:19 AM
BUG?
If I try to edit an action that I have previously created, the program won't save my changes. If I edit the action and press the "Add Action" button, the action appears to be added as a new action but when I try to delete it the program tells me that the xml path was not found.
I love this program...so easy now to utilize of all the user-made dlls at build time.
RizlaUK
11-11-2008, 02:55 PM
i can not recreate the problem, i have edited quite a few actions and made a good deal of files from this app and over the last 2 or 3 days i have had no bugs at all, not even a glith
please run through the steps that caused the error and supply a copy of the xml file.
Imagine Programming
11-11-2008, 05:52 PM
i can not recreate the problem, i have edited quite a few actions and made a good deal of files from this app and over the last 2 or 3 days i have had no bugs at all, not even a glith
please run through the steps that caused the error and supply a copy of the xml file.
I agree with Rizla, the bug i had was a bug in explorer i guess, because it worked fine before and after:) Great application, pretty helpfull aswell:)
RizlaUK
11-11-2008, 06:53 PM
i have found 1 bug, after clicking "New" from the menu the app would throw a error when trying to add a action, i will release a update soon
btw, i had a problem with the taskbar thing to, i have code in preload setting the window position from last run, it seems it was cauesing a strange misplacement of the window, comment code out and it hasent happend again, but it only happend once or twice!
Centauri Soldier
11-11-2008, 07:19 PM
I can't seem to recreate either. The xml file had an <extended> section in it after the error as well but I can't seem to do it again. Weird! Well, cheers just the same Rizla, I love this thing!
P.S. I hope you didn't write this program "as cleverly as possible" ;).
Centauri Soldier
11-11-2008, 10:38 PM
Hey Rizla, I just got an idea. Would it be much trouble for you to put a _CommandLineArgs section into your utility so the user can open a dll file with the program and have it load it into the interface (as opposed to only open being able to open a dll from inside the program)?
Maybe something like
On Startup
if (_CommandLineArgs[1]) then
YOUR OPEN CODE
end
Imagine Programming
11-12-2008, 12:25 AM
i have found 1 bug, after clicking "New" from the menu
btw, i had a problem with the taskbar thing to, i have code in preload setting the window position from last run, it seems it was cauesing a strange misplacement of the window, comment code out and it hasent happend again, but it only happend once or twice!
Strange that it only happens once or twice:P it's a lazy bug:P
ah well, if it's just window centered on startup is nice aswell right?:)
RizlaUK
11-12-2008, 06:07 AM
I can't seem to recreate either.
lol, ah well
On Startup
if (_CommandLineArgs[1]) then
YOUR OPEN CODE
end
its on the todo list :yes
if it's just window centered on startup is nice aswell right?
yeah, it will have to do
the "<extended>" section is where the extra info for the help file is stored, it makes no sence making another file and having 2 files per project when i can just store this info in the already existing xml file, this section causes no errors in the app or in AMS, as long as AMS can read the information it needs for the action editor you can add what you like to the xml, it seemed the only logical way to add and store extra information.
Centauri Soldier
11-14-2008, 12:36 PM
The ability to sort the Actions listbox by name would be great.
The ability to move action augments up and down (in the xml file as well) would also be nice.
Centauri Soldier
11-14-2008, 01:03 PM
Found a bug.
If I try to put Application.GetWndHandle() as the default in an argument, the program wraps it with quotes..."Application.GetWndHandle()"... I can't list a variable as the default augment when requiring a string.
RizlaUK
11-14-2008, 01:39 PM
The ability to sort the Actions listbox by name would be great.
well, that would be a visual thing only, thay would still be in the same order in the help file as enterd in the editor, i could move the xml node as well but i dont really see the need, i'll consider it tho
The ability to move action augments up and down (in the xml file as well) would also be nice.
again, its on the todo list
heres my list of todos for the project
Bugs:
(Fixed v1.0.0.5) a bug where clicking "New" from the menu would cause a error when adding a new action.
(Fixed v1.0.0.5) a bug where clicking "New" from the menu would set the wrong text in the "Add Action" button.
(Unresolved) a bug in arguments window where if datatype a string type and a variable used it gets quoted as a string!! eg: "_SourceFolder.."\\path""
(Fixed v1.0.0.4) a bug in generate html not asking for a file location, it was saving to test file "c:\myfile.html".
(Fixed v1.0.0.4) a bug incopy action not copying all fields.
(Fixed v1.0.0.4) a bug incopy argument not copy note fields.
(Fixed v1.0.0.4) a bug instring/number constraint dialog not clearing or loading right data.
(Fixed v1.0.0.4) a bug in last accessed file not showing in file dialogs, correct path but no file pre selected.
(Fixed v1.0.0.4) a bug in action description note html not being indened to right position.
Inprovments:
1, add "move up" and "move down" buttons to argument listbox to rearrange argument list while keeping xml node id index intact.
2, add menu item to set app/dialogs ontop/not notop.
3, add larger popup edit windows for descriptio and example for esay editing of large text.
4, add notes section to return description.
5, add cmd line arg to open file also make app open last used file if no args sent.
edit:
If I try to put Application.GetWndHandle() as the default in an argument, the program wraps it with quotes..."Application.GetWndHandle()"... I can't list a variable as the default augment when requiring a string.
yeah, i got that, im working on a fix for it, not sure i can catch every type of input tho so i might just add a checkbox, tick it to quote text, untick it to manualy add quotes in case of any variable
for now, add the argument with the default. let it add quotes and save, now open the xml edit window from the tools menu, remove the uneeded quotes and close the window. now it will look correct in the xml and help file as long as you dont edit that argument, if you do then repeate the above steps
Centauri Soldier
11-14-2008, 06:08 PM
well, that would be a visual thing only, thay would still be in the same order in the help file as enterd in the editor...
That would be great. No need to change them in the xml file, it would just be nice to be able to visually search the list alphabetically.
I used this program to add over twenty actions to AMS this morning alone. That would have taken me hours without this program. I appreciate your work on this Rizla.
RizlaUK
11-14-2008, 07:14 PM
Hey, no problem, im just glad its getting used :yes
i'll open the project again tomoz or sunday and finish the bug fixes and start on the updates, if you have any more suggestions or comments on things that need/should be changed then let me know, im open to all options (but no automatic script writer, lol)
Imagine Programming
11-14-2008, 08:50 PM
Some function that's able to scan a *.lua file and list the functions, i have a function written for that somewhere, let me look for it and then i'll pm you:)
RizlaUK
11-14-2008, 09:21 PM
intresting, it could build the raw base of the xml file for you to edit, i could work that into the app, nice idea :yes
also, i tought about saving the xml to another extension and make it open in the app when double clicked and add a export option in the menu so save the xml for AMS, what ya think, do it or leave it ?
Centauri Soldier
11-14-2008, 09:30 PM
I think I would prefer the direct editing as it is. That export might be a good option for saving a user's project as a secondary option.
I'm including the text "Action File Editor" in the menu bar of one of the programs I'm building and having it link to dnet. Will you have a copy the AFE up there when you're done with it or should I link somewhere else?
RizlaUK
11-15-2008, 09:25 AM
I think I would prefer the direct editing as it is.
yeah, on reflection, so would i
Will you have a copy the AFE up there when you're done with it or should I link somewhere else?
yup, i will have a page inplace for the next update :yes
reteset
12-21-2008, 10:19 AM
i have tried to create a help file
it works perfect but i want to split topics in to HTML files individually
i thought , maybe i can edit HTML source but it seems that is impossible :wow
it generates a single line text only
if you could generate HTML source is more readable with (\r\n) this would be very good
or a hidden separator like <!--Action.function--> would be very useful
especially i would like to see an option for generate unique html topic for each action
thank you very much for this great tool
RizlaUK
02-01-2009, 08:22 PM
hey reteset, sorry i dident see this post till now
i have already made such a system for my own use along with a number of bug fixes, i wanted to make a chm help file so i edited it a little to generate single pages as well, i was thinking of generating a exe help file from the single pages but that would mean useing a retail ocx and i would have to charge for the app, and as noone seems to want to pay i figure im waisting my time so i just stopped devlopment
i knida wanted the html to be unreadible, so users have a hard time editing the source of the html, that was the original plan, my tool does the work not notepad
i'll get it finished and sent out to you ASAP, i wont add the ocx tho (as it aint ready yet), you will have to compile the help file in WinCHM or other chm tool (if you want a chm that is)
again, soz for the late reply
Centauri Soldier
02-01-2009, 09:20 PM
I have given CB permission to make the AMS Options 2 program and I had suggested that he ask you for permission to include your idea of the AMS Action File Editor with the program.
If you are not going to continue development would you mind if one of us continued it. It's a fantastic program and I use it all the time...
Thanks,
CS.
clueless
02-01-2009, 10:22 PM
hey nice job :yes
RizlaUK
02-02-2009, 03:53 AM
AMS Option 2 ??
give me some info on the project and i might release the source to you if i deem it to be worth while
but be quick tho coz im on borrowed time with my ISP, i expect it to go any time over the next few days/hours (unless i pay the bill, but that aint going to happen either)
reteset
02-02-2009, 04:51 AM
hey reteset, sorry i dident see this post till now
it is no problem
i am using HTML Help WorkShop to create chm help files
it is easiest part of task
but generating 80 - 100 html topics manually is really a big problem
your tool saves the life on this point
i thought , if we could separate topics in to individual html files
this would be very good for a CHM style help system
thanks for your great job
by the way : i made ListBoxEx's help file with your tool
i just separated topics in to individual html files
and compile as CHM after made some modifications
RizlaUK
02-02-2009, 05:33 AM
yeah i noticed the style of the help file :yes
ok, the multi page system is done, im just adding a few more little things (action/argument sorting etc) and i'll post the update, shouldent take to long now
Centauri Soldier
02-02-2009, 07:44 AM
AMS Option 2 ??
give me some info on the project and i might release the source to you if i deem it to be worth while
but be quick tho coz im on borrowed time with my ISP, i expect it to go any time over the next few days/hours (unless i pay the bill, but that aint going to happen either)
http://www.amspublic.com/viewtopic.php?f=12&t=4 (http://www.amspublic.com/viewtopic.php?f=12&t=4)
Here's the link to AMS Options. CB used it, liked it and wanted to improve on it so I said go ahead. I had all of my functions encrypted and didn't want to share my encryption code.
Anyway, he said he wanted to build the new version from scratch. Having that program and yours combined would be awesome! I'm sure CB would love to get his hands on your source code for integration into AMS Options 2 (Of course he may want to change the title to reflect the compilation). From what I understand, he is adding some more functionality than my original release possesses. I'm sure it'll be great.
Well, I don't want to put too many words in your mouth CB, what do you think about all of this?
RizlaUK
02-02-2009, 11:01 AM
i dont really see the relevance between the 2 apps, your app edits local files of the AMS installation, my app aids the creation of plugins, i think both are handy apps but im not sure both belong in the same tool
anyhow, as CB said "he wanted to build the new version from scratch" then useing my code would be cheating, lol
id be happy to help CB build his own system, but i think i'll hang on to this, i was well pleased with the end result of the help file and iv some more nice little things planed for it (things i want for myself)
Imagine Programming
02-02-2009, 11:31 AM
I think it would be smart to keep AMS Options and AMS Action editor seperated, besides i'm quite busy atm, i've got really long school days all of a sudden... i will still do v2 though
Centauri Soldier
02-02-2009, 02:47 PM
Sounds good guys....just thought I'd throw it out there. :)
RizlaUK
02-02-2009, 03:58 PM
heres an update, i cant access my host right now so i uploaded to a free server, if anyone want to host it then feel free
http://rapidshare.com/files/193099507/AMS_Action_File_Editor-1.0.0.6.exe.html
Chang Log:
--------------------
v1.0.0.6 Update
(Added) user can now generate a single or multiple html help files.
(Fixed) a bug where removing a argument from the listbox would mess up the arg id and cause a error, node id was still intact just wrong id in the listbox.
(Fixed) a bug in the help menu, help file now launches ok.
--------------------
v1.0.0.5 Bugfix
(Fixed) a bug where clicking "New" from the menu would set the wrong text in the "Add Action" button.
--------------------
v1.0.0.4 Bugfix
(Fixed) a bug in generate html not asking for a file location, it was saving to test file "c:\myfile.html".
(Fixed) copy action not copying all fields.
(Fixed) copy argument not copy note fields.
(Fixed) a bug in string/number constraint dialog not clearing or loading right data.
(Fixed) last accessed file not showing in file dialogs, correct path but no file pre selected.
(Fixed) action description note html not being indented to right position.
--------------------
v1.0.0.3 Update
(Added) HTML help generator and a number of inputs for help file information.
--------------------
v1.0.0.2 Update
(Fixed) long loading delay. (caused by plugin object).
(Changed) cleaned up the GUI a bit
(Added) XML text edit dialog.
--------------------
v1.0.0.1 Bugfix
(Fixed) a bug which caused text to not get quoted when string datatypes selected for arguments, now string types are checked for quote tags and added if missing.
(Fixed) multiple bugs in combo items dialog.
(Fixed) wrong text in about dialog title.
some other small code changes made to improve stability.
--------------------
v1.0.0.0 Release
reteset
02-02-2009, 04:36 PM
Excellent !
thanks for new update
it is mirrored to here (http://www.amsplugins.com/details.asp?ID=62&CID=4)
RizlaUK
02-02-2009, 04:53 PM
thanks reteset :yes
Imagine Programming
02-02-2009, 04:55 PM
Nice riz
Info mirror (http://imagine-programming.com/index.php?p=Product&id=4)
Download mirror (http://imagine-programming.com/index.php?p=Product&id=4&act=Download)
Centauri Soldier
02-02-2009, 07:37 PM
Hey cool, thanks for the update Rizla. :yes
vBulletin® v3.8.4, Copyright ©2000-2009, Jelsoft Enterprises Ltd.