MacroSwap - Easy macro copying between flowcharts

Use this section to discuss your embedded Flowcode projects.
Post Reply
mnfisher
Valued Contributor
Posts: 938
http://meble-kuchenne.info.pl
Joined: Wed Dec 09, 2020 9:37 pm
Has thanked: 104 times
Been thanked: 502 times

MacroSwap - Easy macro copying between flowcharts

Post by mnfisher »

A project of sorts.

I'm not sure this is the right place for it - as it's really a PC app.

This app lets you transfer macros from one Flowcode program to another. It's quick and easy to do multiple macros in one easy operation.

Simple load the 'source' flowchart by clicking on 'source' and a target flowchart. Then double click on macros in the left hand list to copy them to the target program.
Then click 'save as' to save the program. Note that by default it uses the target filename - but I'd suggest saving to a new file.



Anyone care to give it a try?

Note it doesn't check if a macro already exists in the target - but if anyone thinks it would be useful then it could 'rename' the copied macro (to a user specified name, or to an automatically generated name (macro_1))

Martin

www.flowcodexchange.com

chipfryer27
Valued Contributor
Posts: 1110
Joined: Thu Dec 03, 2020 10:57 am
Has thanked: 278 times
Been thanked: 397 times

Re: MacroSwap - Easy macro copying between flowcharts

Post by chipfryer27 »

Hi

Running FCv9 on Win8.1

Created two programs, Flowcode1 and Flowcode2. The first one had a Macro, the second did not.

Downloaded your MacroSwap program and not unexpectedly Norton AV wasn't pleased and quarantined it (Covid gets everywhere <s>), most likely due to the low number of people using the program rather than any danger within. A few clicks later and it was running.

Very simple to use. It opened source (Flowcode1) and listed all macros within on the left, same with target (Flowcode2) on right. Double clicking the required macro on the left (source) moved it to the right (target) exactly as you said it would.

I then tried to Save As and chose Flowcode2. After a prompt to overwrite things appeared OK.

However if I then try to open Flowcode2, Flowcode itself crashes. If I then use your program and try and open Flowcode2 nothing appears.

Deleting Flowcode2 and then recreating I tried the above again, but this time Saved As Fowcode3. This created an unspecified file. Adding .fcfx allowed it to be recognised as a FC file but again when opened, Flowcode itself crashes. As before, if I try and use your program to open the file nothing appears.

Probably a bug somewhere and nothing too serious but thought I'd share.

Regards

mnfisher
Valued Contributor
Posts: 938
Joined: Wed Dec 09, 2020 9:37 pm
Has thanked: 104 times
Been thanked: 502 times

Re: MacroSwap - Easy macro copying between flowcharts

Post by mnfisher »

Thanks, I think I slipped a version when I uploaded.

Seems to munge the flowcode badly..

Definitely did work - I'll have a play and repost..

mnfisher
Valued Contributor
Posts: 938
Joined: Wed Dec 09, 2020 9:37 pm
Has thanked: 104 times
Been thanked: 502 times

Re: MacroSwap - Easy macro copying between flowcharts

Post by mnfisher »

Fixed - so for anyone who downloaded before - try again...

Amazing the havoc a typo can play :-(
MacroSwap2.zip
(2.73 MiB) Downloaded 194 times
Martin

stefan.erni
Valued Contributor
Posts: 738
Joined: Wed Dec 02, 2020 10:53 am
Has thanked: 149 times
Been thanked: 170 times

Re: MacroSwap - Easy macro copying between flowcharts

Post by stefan.erni »

Hi Martin

It works perfect! Please more like this.
I think about to use it for update some of my macros.
What about a to choose overwrite or new macro.
Please have a look in the pictures
regards

Stefan


Macro_swap_2021-02-24_9-30-01.png
Macro_swap_2021-02-24_9-30-01.png (167.04 KiB) Viewed 4284 times

mnfisher
Valued Contributor
Posts: 938
Joined: Wed Dec 09, 2020 9:37 pm
Has thanked: 104 times
Been thanked: 502 times

Re: MacroSwap - Easy macro copying between flowcharts

Post by mnfisher »

My thought on this was a dialog with overwrite / rename (user / auto) or cancel..

Indeed it was when I added the check to see if the macro existed in the target FC that I made the mistake :-( I'd pulled it and thought I'd upload to see if anyone thought it was useful...

But - I'm open to suggestions. Auto overwrite/rename??

Martin

chipfryer27
Valued Contributor
Posts: 1110
Joined: Thu Dec 03, 2020 10:57 am
Has thanked: 278 times
Been thanked: 397 times

Re: MacroSwap - Easy macro copying between flowcharts

Post by chipfryer27 »

Hi

Downloaded and tested again. Works fine now in both overwriting and creating a new file.

If the Macro already existed then you would see it in the RH window, or not, so perhaps if it already exists a prompt to overwrite / rename would help prevent accidentally overwriting something unintentionally.

Regards

mnfisher
Valued Contributor
Posts: 938
Joined: Wed Dec 09, 2020 9:37 pm
Has thanked: 104 times
Been thanked: 502 times

Re: MacroSwap - Easy macro copying between flowcharts

Post by mnfisher »

Thanks - at present it doesn't overwrite the macro - just adds it.. Not sure how FC handles two macros with the same name?

Will have a play with the dialog - see if I can get that to work satisfactorily...

Martin

Post Reply