create folder based on the filename

Discuss and share scripts and script files...
Stefan
Posts: 1360
Joined: 18 Nov 2008 21:47
Location: Europe

Re: create folder based on the filename

Post by Stefan »

j_c_hallgren wrote:Oh come on.... :roll: Did you ever think about trying to write these code changes YOURSELF?
There should be the possibility that people just use this product without the need to become an programmer.

If one or another needs to do advanced task which are only (or better/quicker/more nifty) done by an script
and he don't can do that by himself, there should be no harm in asking others for aid.
j_c_hallgren wrote:but I know that some who are do get rather irritated and frustrated by users who keep asking for this and that little change to be coded and never try to learn enough to attempt those changes themselves...there are enough examples found here in forums that should be able to help a new coder, I think.
Who else may be "irritated and frustrated" beside you? If i don't like it i just leave the thread, maybe an tip for you too?

And examples may only help already familiar coders to do an start, not the "just users".
They often even fail on adjusting some parameters to adopt an script on his own needs.

So i think you should be more tolerant on this and let others decide if they are "irritated and frustrated" or not, ok?

Just let users ask questions. That's an forum are there for :wink:

kotlmg
Posts: 321
Joined: 30 Jun 2010 17:14

Re: create folder based on the filename

Post by kotlmg »

sorry my request "hello sir,
to the above code can you please add the option of select destination folder either by typing the path or selecting the path. right now the above script is allowing the user to select path by browsing. i want to type the folder path. can you please add the above option pleaase?" got posted for wrong question. actually i want the above script for moving the multiple folder contents in to different folder. by trial and error method i have used the following the script and it is working.

/* 05.11.2011, Move files and contents of folders to a different (new) folder
::load "<xyscripts>\.snippets\MoveToNewDestination.xys";



*/

setting('BackgroundFileOps', 0);
$destination = input("Enter target path");
$FolderList = get("SelectedItemsPathNames", "|");

foreach($FLD, $FolderList)
{
if (exists($FLD)==2)
{
$content = folderreport("files", "r", $FLD, "r", , "|");
foreach($Item, $content)
{
moveto $destination, $Item;
}
} else {
moveto $destination, $FLD;
}
delete 1, 0, $FLD;
}

admin
Site Admin
Posts: 66258
Joined: 22 May 2004 16:48
Location: Win8.1, Win10, Win11, all @100%
Contact:

Re: create folder based on the filename

Post by admin »

Stefan wrote:
j_c_hallgren wrote:Oh come on.... :roll: Did you ever think about trying to write these code changes YOURSELF?
There should be the possibility that people just use this product without the need to become an programmer.

If one or another needs to do advanced task which are only (or better/quicker/more nifty) done by an script
and he don't can do that by himself, there should be no harm in asking others for aid.
j_c_hallgren wrote:but I know that some who are do get rather irritated and frustrated by users who keep asking for this and that little change to be coded and never try to learn enough to attempt those changes themselves...there are enough examples found here in forums that should be able to help a new coder, I think.
Who else may be "irritated and frustrated" beside you? If i don't like it i just leave the thread, maybe an tip for you too?

And examples may only help already familiar coders to do an start, not the "just users".
They often even fail on adjusting some parameters to adopt an script on his own needs.

So i think you should be more tolerant on this and let others decide if they are "irritated and frustrated" or not, ok?

Just let users ask questions. That's an forum are there for :wink:
Sorry, but I'm 100% with j_c_hallgren here. I'm more and more astonished that forum members keep on replying to a user that is so obviously exploiting them.

And, BTW, what do you mean by "There should be the possibility that people just use this product without the need to become an programmer." ?? Very strange statement...

Stefan
Posts: 1360
Joined: 18 Nov 2008 21:47
Location: Europe

Re: create folder based on the filename

Post by Stefan »

admin wrote: And, BTW, what do you mean by "There should be the possibility that people just use this product without the need to become an programmer." ?? Very strange statement...
I mean that only related to that topic:
no one who likes to use XYplorer AND has advantaged need for an script
should be forced to become a programmer, as he just can ask for an helping hand.

And for the endless update wishes:
it should be normal that the requirement on such an script grows by using it.
And again no average user should have the need to dive into coding, only if he gets more idea,
he can ask for an update, and if no one want or can help any further that should be no problem too.
But if there are more and more request AND if the can be fulfilled by using XYplorer scripting only, ... it's only an compliment to the product and the author.

So i see that more as an advantage for XYplorer. (in the sense: "that is all possible?" :shock: )

admin
Site Admin
Posts: 66258
Joined: 22 May 2004 16:48
Location: Win8.1, Win10, Win11, all @100%
Contact:

Re: create folder based on the filename

Post by admin »

Well, as long as we agree that "there is possibility that people just use this product without the need to become an programmer", I won't stop you spending your time throwing your scripts into a black hole... ;)

Post Reply