Feature Request

Started by JTaylor, November 10, 2021, 06:49:11 PM

Previous topic - Next topic

JTaylor

I sometimes do work where the person wants to utilize html/css/js,etc. but doesn't want the files on the local drive.  This becomes a hot topic every 2-3 months it seems.    My request is to have an option similar to ExtractAttachedFile() but it writes to the ClipBoard instead of to a file.    I've actually had times where this would be helpful in other stuff I do as well.  Thanks.

Jim

kdmoyers

I was thinking to myself that if I needed to do this, I would extract the file to a temp folder, clipboard it, then delete the file.  But then I realized, I don't know how I would "write a file to the clipboard" anyway, so... I have no solution!
How does a person write a file to the clipboard?  What does that actually mean, under the hood?
The mind is everything; What you think, you become.

td

Interesting. Can't say that anyone has mentioned this one before. Of course, this can be done from a compiled script but apparently, there is some reason for not wanting to do it that way.
"No one who sees a peregrine falcon fly can ever forget the beauty and thrill of that flight."
  - Dr. Tom Cade

stanl

Quote from: kdmoyers on November 11, 2021, 04:55:05 AM
I was thinking to myself that if I needed to do this, I would extract the file to a temp folder, clipboard it, then delete the file.  But then I realized, I don't know how I would "write a file to the clipboard" anyway, so... I have no solution!
How does a person write a file to the clipboard?  What does that actually mean, under the hood?


Jim didn't mention if a temp file could be created first, but if so it is possible... but then the script abandons it, or waits around to see what the op wants to do with it... But I cannot speak from experience as I have always used ADO Streams for that stuff.





JTaylor

Meant to change ClipBoard to a variable but forgot.  My apologies.   The person doesn't want it on the drive at all as he is afraid someone will see his code.

Something like:

    my_page = ExtractAttachedFileToString("my_file_name")

It can already be done?  The script would be compiled.   What did I miss?

Jim

td

Don't know anything about the contents of the file - text-based or binary -  or other relevant details but couldn't you create a simple script that reads the file makes the contents into a multiline string and edits the file contents into the compiler source script? You could then have this automagic file start the compile to finish the task. That is how I would do it anyway.
"No one who sees a peregrine falcon fly can ever forget the beauty and thrill of that flight."
  - Dr. Tom Cade

JTaylor

Yes.   That was at the top of my list of solutions if the feature request didn't pan out :)    I sometimes have extensive SQL scripts that would be nice to handle in this way.    Just thought it would save the client extra steps.   Also curious if anyone else ever thought such a feature would be handy. 

Jim

td

It will be added to the ever-expanding list of user enhancement requests.
"No one who sees a peregrine falcon fly can ever forget the beauty and thrill of that flight."
  - Dr. Tom Cade

JTaylor


....IFICantBYTE

I wrote routines years ago that stored files as arrays in scripts.. sounds kind of like what you want.
I haven't used WinBatch for 3+ years now, just read this forum from time to time, but I'll see if I can dig them up from an old pc and post them if you like?
Regards,
....IFICantBYTE

Nothing sucks more than that moment during an argument when you realize you're wrong. :)

JTaylor

Good to hear from you.  Hope all is well.

Appreciate the thought.  I have something that will work but always open to seeing other ideas.   Don't go to a lot of work hunting it down but I am sure others would be interested as well.  Not sure if my Feature request is worth Tony's time but being able to just point the compiler at a file without intermediate steps has a lot of appeal.   

Thanks.

Jim

stanl

Quote from: JTaylor on November 12, 2021, 07:42:47 AM
Just thought it would save the client extra steps.


This implies each client will have the compiler on their PC, or have I totally misunderstood the goal?

JTaylor

I am speaking of a particular one who does and who brings this up on a regular basis.

Jim