Topic: RumFrom,Ram Problem - After become True doesn't come back to False  (Read 1527 times)

0 Members and 1 Guest are viewing this topic.

Aeolis

  • Chef
  • ***
  • Location: Rio de Janeiro, Brazil
  • Date Registered: Oct 2012
  • Posts: 134
Hello folks,

I am using latest MacroLibrary (42.10) and I am facing a problem with Portabilitron script. Portabilitron script has a loop structure where in each loop round it checks at beginning if the entry has a True or False RunFrom,Ram command like that:

RunFrom,Ram,%pCBRRAM_%LoopCount%%

This is the scenario:

Entry 1 - Run from RAM check box state is False
Entry 2 - Run from RAM check box state is True
Entry 3 - Run from RAM check box state is False
Entry 4 - Run from RAM check box state is True
Entry 5 - Run from RAM check box state is False
Entry 6 - Run from RAM check box state is False
Entry 7 - Run from RAM check box state is False

This is the problem:

After the Entry 2 define RunFrom,Ram,%pCBRRAM_%LoopCount%% as RunFrom,Ram,True all the other entries are treated as True too. Even if I forcibly state at the end of each loop RunFrom,Ram,False (to force it reset to False and change only when receiving a True state) it still treat all the subsequent entries as True.

It seems that when RunFrom,Ram, receives a True statement it ignores other changes to its value.

I hope you can help me here.

Best regards,

Aeolis


Re: RumFrom,Ram Problem - After become True doesn't come back to False
« Reply #1 on: January 13, 2013, 01:20:55 PM »

Lancelot

  • Moderator, Gena Baker
  • Grand Chef
  • *****
  • Date Registered: Sep 2010
  • Posts: 6984
Yes, only True value accepted  :thumbsup:

What you face is known situation,
 which never required, Idea "False" reserved to be implemented,
I made some set of works on Macro Library (not activated) to work on False etc. case in some far future,
  besides due to verrry low priority (1 in ~4 years I am around) ,
   with quite high priority tasks at hand this one still posponing  :wink: with low, limited time :turtle:
    since there is a nice no trouble way available (even required by one  :wink:) which I am waiting someone ask for ~4 years  :lol: :lol:

You can put to your plugin end, even when using loop  :wink:

I do not know your plugin well, but quick looking interface I know this idea well, not my taste,
  I had created Plugin Creators to easly make *individual plugins which is more my taste  :wink:

Anyway, back to way for your loop codes,
This will give you idea:


Code: [Select]
//At VERY Begining of process
Call,DirDelete,%ProjectTemp%\Portabilation
DirMake,%ProjectTemp%\Portabilation
FileCreateBlank,%ProjectTemp%\Portabilation\PortabilationRAM.ini
//--
//--
//--
//-->During Loop when there is RunFrom,Ram,True write relevant (whatever) to PortabilationRAM.ini
//Example:
TxtAddLine,%ProjectTemp%\Portabilation\PortabilationRAM.ini,"Echo,#$qI want to Run from RAM#$q",Append
//--
//--
//--
//At the end of process
TxtAddLine,%ProjectTemp%\Portabilation\PortabilationRAM.ini,"RunFrom,Ram",Prepend
TxtAddLine,%ProjectTemp%\Portabilation\PortabilationRAM.ini,"[PortabilationRAM]",Prepend
Run,%ProjectTemp%\Portabilation\PortabilationRAM.ini,PortabilationRAM
Call,DirDelete,%ProjectTemp%\Portabilation


*
btw, I know you do not like/listen advices,
anyway, variable inside variable is a dangerous way %pCBRRAM_%LoopCount%%
only informing, even you do not listen you will understand one day remembering somebody* told/wrote you  :thumbsup:

:ymca:

edit: minor fix on codebox after Macro Library update  :thumbsup:
« Last Edit: January 19, 2013, 02:20:39 AM by Lancelot »

Re: RumFrom,Ram Problem - After become True doesn't come back to False
« Reply #2 on: January 17, 2013, 10:49:40 AM »

Lancelot

  • Moderator, Gena Baker
  • Grand Chef
  • *****
  • Date Registered: Sep 2010
  • Posts: 6984
Hi Aeolis,

I worked passing days to finalize RunFrom syntax, New Macro Library now available on all projects  :thumbsup:
http://theoven.org/index.php?topic=452

Aside , If you use above workaround I posted, it will continue working   :thumbsup:

Plugin Creators may also take interest , or not...
http://theoven.org/index.php?topic=178

Re: RumFrom,Ram Problem - After become True doesn't come back to False
« Reply #3 on: January 19, 2013, 01:49:16 AM »

Aeolis

  • Chef
  • ***
  • Location: Rio de Janeiro, Brazil
  • Date Registered: Oct 2012
  • Posts: 134
Dear Lancelot,

Thank you for your hard work. :thumbsup:

Best regards,

Aeolis
« Last Edit: January 19, 2013, 01:49:31 AM by Aeolis »

Re: RumFrom,Ram Problem - After become True doesn't come back to False
« Reply #4 on: January 19, 2013, 02:24:41 AM »

Lancelot

  • Moderator, Gena Baker
  • Grand Chef
  • *****
  • Date Registered: Sep 2010
  • Posts: 6984
 :thumbsup:

out of topic:
I remember there were "All User Profile" hardcode on one of your plugins  (firewall) that "had" taken my attention

Anyway, We also updated projects for none-hardcode way  :wink:
Code: [Select]
IniRead,%ProjectDir%\Script.Project,BasePath,AUAppdata,%AUAppdata%
Set,%TargetAllUserAppData%,%TargetProfilesBaseDir%\%AUAppdata%

side by side, here is "User Profile" in case needed one day (which is generally more needed on Some* Applications)
Code: [Select]
IniRead,%ProjectDir%\Script.Project,BasePath,Appdata,%AppData%
Set,%TargetUserAppData%,%TargetProfilesBaseDir%\%AppData%

Re: RumFrom,Ram Problem - After become True doesn't come back to False
« Reply #5 on: January 19, 2013, 02:48:52 AM »

Aeolis

  • Chef
  • ***
  • Location: Rio de Janeiro, Brazil
  • Date Registered: Oct 2012
  • Posts: 134
Dear Lancelot,

Yes, you're right. It is Privatefirewall script. Thank you again. I will update it using the new syntax. :thumbsup:

Best regards,

Aeolis

 

Powered by EzPortal