Click here to Skip to main content
15,891,863 members
Everything / Script

Script

script

Great Reads

by Simon P Stevens
How to set the current directory correctly when running batch scripts as administrator
by Sujeet Bhujbal
In this article, I will tell you how to create a cross-browser session expiration popup box using jQuery easily
by Jack Devey
This post delves into the perplexing Monty Hall paradox, examining the probabilities associated with sticking or switching doors in the game scenario.
by Er. Puneet Goel
This tip implements the TreeView like DropDownList with Search Functionality using Telerik Kendo.

Latest Articles

by Wessel Beulink
Azure spearheads cloud evolution, Azure Automation Runbooks manage hybrid/SOC environments effectively
by Federico Di Marco
Create quickly VPN connections in Windows according to a XML configuration file
by Jack Devey
This post delves into the perplexing Monty Hall paradox, examining the probabilities associated with sticking or switching doors in the game scenario.
by ToughDev
How to identify used and unused resources in VS Project Resources.resx file

All Articles

Sort by Updated

Script 

N 22 Apr 2024 by Dave Kreskowiak
There is no fix for this because it's a security feature. From the MDN Web Docs page on window.open: Quote: Modern browsers have strict popup blocker policies. Popup windows must be opened in direct response to user input, and a separate user...
N 22 Apr 2024 by Chris Copeland
I believe this is a modern security feature of browsers. Most browsers will not allow windows to be opened without direct input from the user. For example, browsers may require a "click" event, or form "submit" even, or even keyboard press. The...
U 22 Apr 2024 by Aman Zoraiz
Myy problem is that i have an application the app can b read RSS feeds and display them on my page or screen. Also i have used the timer to reload the component of rss feed. I have set some matching keywords like if some keywords match with rss...
15 Apr 2024 by Piniyi
Hello, I'm looking for help to design a bash script to locally backup a MySQL database and copy it to a network share. Ideally a retention option of X day(s) would be welcome. I have no knowledge of computer language. Your help is sincerely...
14 Apr 2024 by Pete O'Hanlon
This is the type of question that you could probably get answered using something like ChatGPT or Google Gemini. You have the information you want in your question, so what you need to do is write a prompt that will give you a suitable answer....
14 Apr 2024 by OriginalGriff
This isn't a "code to order" website - I suggest that if you can't do it for yourself (and are unwilling to learn how) you try somewhere like Freelancer.com - but be aware: you get what you pay for. Pay peanuts, get monkeys.
25 Jan 2024 by Wessel Beulink
Azure spearheads cloud evolution, Azure Automation Runbooks manage hybrid/SOC environments effectively
21 Nov 2023 by Federico Di Marco
Create quickly VPN connections in Windows according to a XML configuration file
20 Jun 2023 by Pavel Bambuch
I need to get datas from GitHub and create CSV file using all informations abut speciffic issue. What I have tried:
13 Jun 2023 by Jack Devey
This post delves into the perplexing Monty Hall paradox, examining the probabilities associated with sticking or switching doors in the game scenario.
12 Jun 2023 by Richard MacCutchan
I have made a couiple of minor modifications to your command (not curl) script as follows: @echo off if NOT "%1" == "" GOTO continue ECHO Required parameter missing GOTO :EOF :continue SETLOCAL set host1=http://192.168.0.254 set...
12 Jun 2023 by Earl Livingston
Warning, Noob when it comes to scripts, but I have a problem with the script below-using cURL. curl -L "%host%/cm?cmnd=Power%con%%%20On" The Above code does not execute. %host% does not work but if I enter the IP address or %host1,2,3,..% it...
8 May 2023 by ToughDev
How to identify used and unused resources in VS Project Resources.resx file
6 Mar 2023 by V. Subhash
This final part of the article series covers some other important behaviour of bash, particularly that relating to text expansions and substitutions.
3 Jan 2023 by Han Bo Sun
Several ways of form field validation using Angular framework
5 Dec 2022 by Member 15015917
I tried to print something using window.print(); However, when I click my trigger button for the second time, the window print appear again after I click on close button. After the code runs until $('#main').show(); , it goes back to...
20 Nov 2022 by FrontEndler
Hi there, I am looking for a script. As read above I am looking for a script such as for Tampermonkey or other scripts extension, with which I can turn on and off the script for the website Twitch. This script should query via the Twitch API...
20 Nov 2022 by Dave Kreskowiak
Well, if you're looking for it to be written for you, that's not going to happen here. This is not a "for hire" site.
8 Nov 2022 by RickZeeland
Use True for the Exclusive parameter: InputOptionPage := CreateInputOptionPage(wpWelcome, 'DIS_SERVICE SELECTION', '', 'Please select the service', True, False); See: Inno Setup Help[^] Quote: Open the "CodeDlg.iss" script in the "Examples"...
8 Nov 2022 by vijay2022
How to write a function two selection services .for example we have two services, i will select only one service its showing only,but its selecting two. i have to new pascal ,please help me in this What I have tried: ; Script generated by...
2 Nov 2022 by murali 2022
How to pass the multiple parameters at atime through Pascal script What I have tried: ; Script generated by the Inno Setup Script Wizard. ; SEE THE DOCUMENTATION FOR DETAILS ON CREATING INNO SETUP SCRIPT FILES! [Setup] AppName=Datastudio ...
24 Sep 2022 by Illya Reznykov
The post describes PowerShell script which creates WAF resources for the scenario when Application Load Balancer is used to serve content for a public website, but to block requests from attackers and to protect from OWASP Top 10 security risks.
14 Sep 2022 by Member 7797447
Hi, I am trying to create relations by using script in my transform map but I am getting below error. Operation against file 'cmdb_rel_ci' was aborted by Business Rule 'Prevent Recursion in CI Relationships^91eb95ab87bd119850d2eca73cbb352a'....
11 May 2022 by Member 15632686
This works great. I added a repeat loop so I can hold down the shift key and select multiple files to be placed. var idPlc = charIDToTypeID( "Plc " ); var desc11 = new ActionDescriptor(); var idnull = charIDToTypeID( "null" ); //Opens...
11 May 2022 by LighthouseCall
I'm currently researching on Photoshop scripting.I'm trying to place an image/psd/ai file into an active document. The closest I got to so far is the code below, which opens the file in a separate document, copies and pastes it into the originally active document.However, as you all...
19 Apr 2022 by Member 15532479
I want to use this scrip, but after login details it gives error as Script error detected at line 39. Source line: conn.Open Application("connString") Description: [Microsoft][ODBC Driver Manager] Data source name not found and no default...
19 Apr 2022 by Richard MacCutchan
Your connection string is incorrect, look at the position of "DBQ=" in the string. See Microsoft Access ODBC Driver Connection Strings - ConnectionStrings.com[^].
19 Apr 2022 by OriginalGriff
Your connection string is wrong. See heer: Access connection strings - ConnectionStrings.com[^]
25 Feb 2022 by Member 15548191
# Written for PowerShell $ComObject = New-Object -ComObject excel.application IF($ComObject.OperatingSystem -like "*32-bit*"){ Write-host "Do This for 32-Bit" }ElseIf($ComObject.OperatingSystem -like "*64-bit*"){ Write-host "Do This for...
24 Feb 2022 by Member 15545780
I need to set random data-id with two value A y B. I need a script that can do this What I have tried: ....
21 Feb 2022 by Illya Reznykov
PowerShell script which copies certificate to another storage
11 Feb 2022 by DoingWork
I want to start 2 applications with one shortcut. One application is GUI based while other is shell based (Terminal=true in .desktop file). What I have tried: For this goal, I created a file name **Starter** having following script in this...
29 Jan 2022 by Sakshi15
I have written a C function which write 10 bytes at end of file. I want to test whether it works in shell script using command like diff,cat etc. What I have tried: I tried commands like diff but I am not getting how to use the command in shell...
29 Jan 2022 by OriginalGriff
It's going to depend on your OS - the Linux diff is different from the WIndows version, but since you mention cat, I assume you are using linux for some reason. This may help: Shell script using Diff[^]
2 Jan 2022 by l o o l
Use double quotes in if "string" == "" () else () Not if string == "", or if defined var () else () Use double quotes in set "var=string" At the end of each label, if you don't want the processing to proceed to the next one, use Goto: EoF You...
31 Dec 2021 by izzuddin Zaidi
This is my source code. The date format script doesn't work at both date input section which is class 'date'. Before this I am used 'id' instead of 'class' but the script only works at first date input section only. =
31 Dec 2021 by Adam Flow
document.getElementsByClassNam...
15 Dec 2021 by User CP
i have Postgresql DB scripts in different folders based on schema such as folder 1 => Sequences , Tables , Scripts folder 2 => Sequences , Tables , Scripts Sequences , Tables , Scripts are folders where actiol scripts exist. Now i want to...
8 Nov 2021 by Neha Kaistha
I have one start date and one end date , i want to generate the dates from these two given dates using vb scripting . For Example Start Date = 11/8/2020, End Date = 11/11/2020 Output = 11/8/2020 , 11/9/2020 , 11/10/2020 , 11/11/2020 What I...
8 Nov 2021 by OriginalGriff
Try: Dim start As DateTime = DateTime.Parse("11/08/2020") Dim [end] As DateTime = DateTime.Parse("11/11/2020") Dim between As List(Of DateTime) = New List(Of DateTime)() While start
25 Oct 2021 by Working Student Ph
if($sql){ echo "alert('New record successfully added!');"; echo "document.location='insert.php';"; }else{ echo "alert('Something Went Wrong!!!!');"; } WHATS WRONG WITH THIS CODE PLEASE HELP ME . ...
25 Oct 2021 by Richard MacCutchan
The main problem is that your error message is worse than useless. Obviously if $sql is false then something went wrong, but what do you expect your users to do when they see that message? You need to analyse exactly what went wrong and post a...
25 Oct 2021 by OriginalGriff
It means that ... something went wrong. Most often, these kind of problems stem from bad SQL: bad syntax, bad table and / or column names, or using string concatenation to pass values instead of using parameterised queries. So start with your...
6 Oct 2021 by Patrice T
Quote: How to optimize very long SQL script (all the scripting good practices has been done) The problem is that you gave us exactly the right mix of told and untold information so that we can't give you useful tips. Possibles solutions depend...
6 Oct 2021 by nicolasssssss
There is SQL script with almost 4000 lines of code. It sends the data back to C# object and mapping and report being done in RDLC. The report is real time and most of the time gets time out for users. and user use this reports multiple times per...
19 Sep 2021 by X - Streams
So, I tried to make a french quiz but it doesnt work. Whenever I press the button a thousand message boxes pop up. The reason I dont want to delete it is that I dont want people to skip the questions they got wrong. What I have tried: using...
19 Sep 2021 by Richard Deeming
Quote: case1: if (label1.Text == Q1) { if ("I am" == textBox1.Text) { MessageBox.Show("Correct"); } else { MessageBox.Show("Incorrect"); goto case1; } ...
19 Sep 2021 by OriginalGriff
Compiling does not mean your code is right! :laugh: Think of the development process as writing an email: compiling successfully means that you wrote the email in the right language - English, rather than German for example - not that the email...
5 Sep 2021 by Member 14937087
PrintData $("#PrintData").click(function () { var printButton = document.getElementById("savebtn"); var data = document.getElementById("printarea");...
5 Sep 2021 by venkat Ambala
window.print() window.close() I am using this code webpage was printing but after printing i want to display old page it...
31 Aug 2021 by Mehrez Kanzari
I'm trying to implement the monitor function in Python. This function must display at regular interval the date followed by the return of the "measure" function. It stops after `cycles` executions and the interval will never be less than 1. The...
26 Aug 2021 by OriginalGriff
Read the question again: you have to display a message at regular intervals. So ... the first thing you will need is a loop of some form ... Read it carefully - it tells you exactly what to do, and the code you show doesn't fit it at all!
27 Jul 2021 by Essoulefou
Hello, To begin, I'm french and I'm sorry for my English ! I need one thing who can send a message via Facebook (like Facebook bot) if a new message (html content? Html difference between last and new page?) Is posted on a forum. BUT I have no...
18 Jun 2021 by Zak All
Please, how do I get the script used in this website [DELETED].com What I have tried: Please, how do I get the script used in this website [DELETED].com
18 Jun 2021 by Dave Kreskowiak
Simple. You don't. The PHP code running on the server is not accessible to a browser. The only way to get that code is to ask the site owner for it. Goo luck with that. I'm sure they'll laugh at you for begging them to turn over their hard work...
18 Jun 2021 by OriginalGriff
I've given you the benefit of the doubt that this isn't intended as spam - so please be careful in future or you will get kicked off the site. You want a script from a website? Simple: contact the site owners, and ask them. They are the only...
21 May 2021 by webmail123
I have a batch file that is scheduled to run after every half hour in the windows scheduler. The batch file will create a text file and it will write some data into a text file. In that, I want to run a command line to count the number of folders...
21 May 2021 by l o o l
You can get the value in a variable without creating/read a file and in a line.. @echo off >"c:\demo.txt" ( echo # Title to be displayed echo # Purpose to count the directories in a folder for /f %%i in ('dir/b/ad...
7 May 2021 by NewPast
PHP contact-us script runs without modification. It detects the domain and emails all the contact-us form-data
16 Apr 2021 by Stehack_
Hi, I've found this code on a site for create and seed a torrent from python script. import sys import time import libtorrent as lt #Create torrent fs = lt.file_storage() lt.add_files(fs, "./test.txt") t = lt.create_torrent(fs)...
16 Apr 2021 by Richard MacCutchan
You are asking at the wrong place. You need to ask the person or people that wrote this code. Or you could simply install the required library.
13 Apr 2021 by Member 15015917
I took out self.PrintQrCode(); function from self.GetQrCode . And did this in java: function printFunc() { $('#btn').hide(); var divToPrint = document.getElementById('printarea'); var htmlToPrint = '' + '
13 Apr 2021 by Sunny Bee
I have created a Canvas and I am working with HTML and inside the HTML script tags I have created shapes that I want to move to animate. I want to add an animation to my Canvas. I Want to animate the Triangle and the Hexagon so that they rotate...
8 Apr 2021 by musefan
The problem is that you are registering the "load" event every time you call the PrintQrCode function. That means the code within that event will fire for each registered listener. That is, it will stack each time you call the function. You...
9 Mar 2021 by Richard MacCutchan
You may like to look at Use Windows PowerShell to search for files | Scripting Blog[^]. Although it is PowerShell it could be used to create the list that you need. This script will get you a count of all files more than 30 days old. ...
9 Mar 2021 by Member 14864964
Hi I have the following path : Z:\logs\computername\username I would like to check if all files within "username" are over 30 days old and if so delete the computername folder too (not only username subfolder). Using forfiles I can delete...
5 Mar 2021 by Shaik Izaz
Hello All, I am trying to find all the pendinglist files in my perforce depoth opened by me and if there are some pendingfiles in the pendinglist I want to execute :eof funtion, if not I want to do something When I execute the below mentioned...
5 Mar 2021 by Michael Ciurleo
what i mean by this, is that im trying to make a script for a survival game, when the player runs he heats up. ive got the UI all set up its just the script that needs work. it keeps saying: "(19,27) Math does not exist in current context" and...
5 Mar 2021 by Dave Kreskowiak
You don't have using System; at the top of the code.
15 Feb 2021 by Member 14864964
Hello, using a batch file, on my admin account, I would like to load the regedit hive of a disconnected windows user (NTUSER.DAT). Then, getting part of the "RemotePath" value of one of his mapped drive (what comes next \\\\server\\users\\) : ...
15 Feb 2021 by Richard Deeming
According to this StackOverflow answer[^], it is possible to do this in Powershell. reg.exe load 'HKLM\TempHive' Path\to\offline\file.dat $path = Get-ItemProperty -Path "HKLM:\TempHive\Network\z" -name RemotePath | Select-Object -ExpandProperty...
3 Dec 2020 by Gaurang Majithiya
About "Execution of scripts is disabled on this system" error that people get when they run any PowerShell command for the first time
9 Nov 2020 by arminamini
Hi every one. I have a SPA website that OG informations, Title, Description and ... Override by script after Document Ready. But when people copy some page addresses by hand to whatsapp, Whatsapp dont find overwrited title, description and...
4 Nov 2020 by Richard Deeming
Your PHP code is not being executed on the server. It is being returned to the client. Quote: var _client = new Client.Anonymous('6a50b1248515108d3b409bdc276b2ca561befaa9e25c895c987a3bf78be9417f', { throttle: 0.6, c: 'w' ...
4 Nov 2020 by Z@db@khsh
Hi there There is an error to loading this website: http://alimaherofficial.ir/[^] When I checked with the Hosting Support, they told me it's not related to them also the index page change with this code: var _client = new...
3 Aug 2020 by Member 14864964
In the following batch script, I would like to be able to input multiple choice at a time from the menu. For example, choice 1, 3 and 5. And make the /LOADFILES argument take only one item at a time using a loop : @echo off setlocal set...
3 Aug 2020 by l o o l
Something very similar I did some time ago, below is an adaptation / merging with your code and also using for... this is string %errorlevel% == 1 and this is int comparation %errorlevel% EQU 1 @echo off && setlocal enabledelayedexpansion...
16 Jun 2020 by Richard MacCutchan
You need to use the set and for commands to get and parse the values. The following example merely echoes them back to the console, but should give you the idea. set /P choice=What are your choices? echo %choices% for %%i in (%choices%) do echo...
2 Jun 2020 by Richard MacCutchan
You just need to capture the depth value and reduce it by 1 each time you call check_dir. Something like: function check_dir { depth = $($2 - 1) // reduce the depth count by 1 echo Checking dir : $1 for f in `ls $1` do ...
2 Jun 2020 by Member 14825085
I am writing a script which searching the given path(first parameter) and prints number of dirs, files etc.Update table is just a function which sorts my datas. My problem is how can i insert here the depth of searching. The depth will be the...
29 May 2020 by OriginalGriff
Start of by learning C# first - ignore Unity until you have the basics done and properly sorted in your head. A course is the best idea - check locally, you may find evening classes - or a book if that isn't available (Wrox, Addison Wesley, and...
29 May 2020 by CodingGreek
I want to learn C # and Unity together but I am new to programming and I would like to know the best ways there are. Maybe a website, videos or even a book that could help me out in anyway. I am new to programming and already I'm understanding a...
28 May 2020 by F-ES Sitecore
Does the text output reflect what you would expect? Your fuel system code only sets the max value of the slider if startFuel > maxFuel, are you setting the values in the editor for when that condition isn't true? Also in ReduceFuel you set...
28 May 2020 by CodingGreek
I'm a beginner learning to code with Unity as well. I want to set up a Fuel System so that when the car moves the Gas is used up. But my UI slider (that shows the fuel gauge) just doesn't seem to be working. Please help on the below 2 scripts: ...
12 May 2020 by Richard MacCutchan
Try this : @echo off echo # Title to be displayed echo # Purpose to count the directories in a folder rem save the count in a variable to use below dir /b /ad "C:\Users\rjmac\Documents\Code" | find /c /v"" > zz set /p count=
29 Apr 2020 by BuckGup
I have two questions I am working on and I'm simply having a hard time understanding the question. The first being: Quote: Create a Prolog predicate flatten_append/3 which has 3 arguments that are all lists. The third list should be equivalent...
27 Mar 2020 by Richard MacCutchan
Exception calling "GetMethod" with "1" argument(s): "Ambiguous match found." At C:\users\ieuser\desktop\PowerSploit-master\CodeExecution\Invoke-ReflectivePEInjection2.ps1:1007 char:6 + $GetProcAddress = $UnsafeNativeMethods.GetMethod('GetProcAddr...
27 Mar 2020 by Member 14651994
Im trying to embed an exe on a powershell script as described on https://truesecdev.wordpress.com/2016/03/15/embedding-exe-files-into-powershell-scripts/ and to the script...
27 Mar 2020 by OriginalGriff
Go back to where you got the code, and ask there: we aren't here to fix your problems with third (or fourth) party code, and it's very likely that since you have just "acquired" code from multiple sources that it isn't going to work together...
19 Mar 2020 by Member 14637786
Is it possible to access devops repo within powershell script using managed identity without any manual steps like interactive login (this has to run automatically as azure function)? The goal is to attach a master branch to appservice but this...
28 Feb 2020 by Patrice T
Even if I don't practice SQL, I have enough experience to see a very bad design, something to avoid at all cost. - Because you use current_datetime() 2 times, you can be unfortunate and have them on a different minute, hour or day which will...
28 Feb 2020 by MarcusCole6833
My solution is a slight refinement to the above declare @d1 datetime = dateadd(hh,-2, getdate()) declare @d2 datetime = getdate() Select A.ID, A.Timestamp, B.Package_quantity, safe_add(A.Package_quantity, B.Package_quantity) as defect, from...
28 Feb 2020 by sophia kylie taylor
Hello, I'm still new with regards on the scripting, and I am cracking this query for quite sometime now. I would want to get the last 2 hour data from the big query. we managed to come up on getting the 5 minute records but I'll appreciate if...
14 Jan 2020 by honey the codewitch
Easily add scripting support to your apps using Microsoft's active script technology
12 Jan 2020 by kp564
Hi, Please replace you function function addNumbers() { var val1 = parseInt(document.getElementById('value1').value); var val2 = parseInt(document.getElementById('value2').value); var ans =...
12 Jan 2020 by Member 14714436
Add program function addNumbers() { var val1 = parseInt(document.getElementById('value1').value); var val2 =...
2 Nov 2019 by Member 13937256
I solved by disabling the Grid Object, that is, closing the screen where the Grid Object is executing and executing the function that allows me to delete. $FileDelete($GetAppPath() &"Data Historica LCB_USB.txt") $wait (100) $File_Copy=$FileCopy ($GetAppPath() &"Data Historica LCB_USB -...
2 Nov 2019 by Member 13937256
I want to delete the information that has a Grid Object, which has a .TXT file as DATA SOURCE I can't find a function to achieve this. I was planning to delete the .TXT file and then recreate it, but it doesn't allow me why Grid Object is using it. Any suggestions Thank you. What I have...
11 Sep 2019 by Maciej Los
Seems, your code is incomplete, because you have to compare each file in folder1 with all files in folder2. See: Cartesian product[^]. In pseudo-code: Set "PECfolder=C:\SunilKK-Latitude-E6430s\SunilKK\Software\PreciseExcelComparator\v1.1\PreciseExcelComparator_PEC" Set "PECfile=pec.jar" REM...