Overclock.net › Forums › Software, Programming and Coding › Operating Systems › Windows › I want a message asking "Are you sure you want to open this?" for some programs.
New Posts  All Forums:Forum Nav:

I want a message asking "Are you sure you want to open this?" for some programs. - Page 4

post #31 of 51
Thread Starter 

Yep. I think I'm going to use larsch's solution. This is good.

It's a computer!
(19 items)
 
  
CPUMotherboardGraphicsRAM
i5-2500K @ 4.5GHz (1.368-1.384V fixed voltage) ASUS P8P67 EVO B3 (UEFI ver. 1850) GTX 780 ASUS DirectCU II (1228 / 6300, 1.180V) G.SKILL Ripjaws X 8GB (2 x 4GB) 1866MHz, CL9 
Hard DriveHard DriveHard DriveOptical Drive
250 GB Samsung 840 EVO (C:\) 250 GB Samsung 840 EVO (D:\) 150 GB WD VelociRaptor Samsung SH-S243N 24x DVD Burner 
Optical DriveCoolingOSMonitor
Samsung SH-S203N 20X DVD Burner Thermaltake Frio Win 7 Home Premium x64 SP1 Retail AOC G2460PG (24" 1920 x 1080 144Hz G-SYNC) 
KeyboardPowerCaseMouse
Filco Majestouch 104-key Cherry MX Blues w/NKRO Corsair HX650 (Bronze, ordered on 12-12-2009) CM 690 Intellimouse Optical (1.1A) 1000Hz polling rate 
Mouse PadAudioAudio
Basic, but premium round X-Fi Titanium HD Klipsch ProMedia 2.1 (with 16 AWG Monster Cable... 
  hide details  
Reply
It's a computer!
(19 items)
 
  
CPUMotherboardGraphicsRAM
i5-2500K @ 4.5GHz (1.368-1.384V fixed voltage) ASUS P8P67 EVO B3 (UEFI ver. 1850) GTX 780 ASUS DirectCU II (1228 / 6300, 1.180V) G.SKILL Ripjaws X 8GB (2 x 4GB) 1866MHz, CL9 
Hard DriveHard DriveHard DriveOptical Drive
250 GB Samsung 840 EVO (C:\) 250 GB Samsung 840 EVO (D:\) 150 GB WD VelociRaptor Samsung SH-S243N 24x DVD Burner 
Optical DriveCoolingOSMonitor
Samsung SH-S203N 20X DVD Burner Thermaltake Frio Win 7 Home Premium x64 SP1 Retail AOC G2460PG (24" 1920 x 1080 144Hz G-SYNC) 
KeyboardPowerCaseMouse
Filco Majestouch 104-key Cherry MX Blues w/NKRO Corsair HX650 (Bronze, ordered on 12-12-2009) CM 690 Intellimouse Optical (1.1A) 1000Hz polling rate 
Mouse PadAudioAudio
Basic, but premium round X-Fi Titanium HD Klipsch ProMedia 2.1 (with 16 AWG Monster Cable... 
  hide details  
Reply
post #32 of 51
Thread Starter 
Quote:
Originally Posted by ASUSfreak View Post

Can't you make the icons bigger? Or by lowering the desktop resolution (they also become bigger)

That way you have less chance to hit the wrong button smile.gif

 

 

Quote:
Originally Posted by Quantum Reality View Post

I dunno if you can boost the size of the taskbar; Win7 already uses some pretty generous icon sizes. I can check though, will edit this in a moment.

Never mind, if I have to screw with the display sizes and whatnot it makes me log out, which I'm not gonna do just for a quick test.

 

lol trust me, I'm not gonna do that. :)

It's a computer!
(19 items)
 
  
CPUMotherboardGraphicsRAM
i5-2500K @ 4.5GHz (1.368-1.384V fixed voltage) ASUS P8P67 EVO B3 (UEFI ver. 1850) GTX 780 ASUS DirectCU II (1228 / 6300, 1.180V) G.SKILL Ripjaws X 8GB (2 x 4GB) 1866MHz, CL9 
Hard DriveHard DriveHard DriveOptical Drive
250 GB Samsung 840 EVO (C:\) 250 GB Samsung 840 EVO (D:\) 150 GB WD VelociRaptor Samsung SH-S243N 24x DVD Burner 
Optical DriveCoolingOSMonitor
Samsung SH-S203N 20X DVD Burner Thermaltake Frio Win 7 Home Premium x64 SP1 Retail AOC G2460PG (24" 1920 x 1080 144Hz G-SYNC) 
KeyboardPowerCaseMouse
Filco Majestouch 104-key Cherry MX Blues w/NKRO Corsair HX650 (Bronze, ordered on 12-12-2009) CM 690 Intellimouse Optical (1.1A) 1000Hz polling rate 
Mouse PadAudioAudio
Basic, but premium round X-Fi Titanium HD Klipsch ProMedia 2.1 (with 16 AWG Monster Cable... 
  hide details  
Reply
It's a computer!
(19 items)
 
  
CPUMotherboardGraphicsRAM
i5-2500K @ 4.5GHz (1.368-1.384V fixed voltage) ASUS P8P67 EVO B3 (UEFI ver. 1850) GTX 780 ASUS DirectCU II (1228 / 6300, 1.180V) G.SKILL Ripjaws X 8GB (2 x 4GB) 1866MHz, CL9 
Hard DriveHard DriveHard DriveOptical Drive
250 GB Samsung 840 EVO (C:\) 250 GB Samsung 840 EVO (D:\) 150 GB WD VelociRaptor Samsung SH-S243N 24x DVD Burner 
Optical DriveCoolingOSMonitor
Samsung SH-S203N 20X DVD Burner Thermaltake Frio Win 7 Home Premium x64 SP1 Retail AOC G2460PG (24" 1920 x 1080 144Hz G-SYNC) 
KeyboardPowerCaseMouse
Filco Majestouch 104-key Cherry MX Blues w/NKRO Corsair HX650 (Bronze, ordered on 12-12-2009) CM 690 Intellimouse Optical (1.1A) 1000Hz polling rate 
Mouse PadAudioAudio
Basic, but premium round X-Fi Titanium HD Klipsch ProMedia 2.1 (with 16 AWG Monster Cable... 
  hide details  
Reply
post #33 of 51
I just realized the way I did it could mean unnecessary extra copies of the vbs file all over. I emphasize I was doing proof of concept only, not implementing this for myself so it was rather rushed.
4690K System
(12 items)
 
HTPC
(9 items)
 
HP dv6 laptop
(13 items)
 
CPUMotherboardGraphicsRAM
Core i5 4690K ASRock Z97 Extreme4 XFX Radeon 7950 32 GB DDR3-2133 
Hard DriveOptical DriveCoolingOS
Samsung 850 EVO SSD Samsung DVD/CD-writer Corsair Hydro H60 Windows 7 
MonitorMonitorPowerCase
ASUS PA248Q Dell U2412M XFX 850W Black Edition XXX Fractal Design Arc Midi 2 
CPUMotherboardGraphicsRAM
Pentium Dual Core E6700 MSI G41M-P33 Combo ATI HD4350 Kingston ValueRAM DDR3-1333 
RAMHard DriveOSMonitor
Kingston ValueRAM DDR3-1333 WD Caviar Blue Windows 7 64-bit Sony 32" TV set 
Case
Apex TX-381 
CPUGraphicsRAMHard Drive
Core i5 430M GT230M (1 Gb dedicated) 8 GB DDR3-1066 640 GB 
OSMonitor
Windows 7 Home Premium (64-bit) 15.6" 
  hide details  
Reply
4690K System
(12 items)
 
HTPC
(9 items)
 
HP dv6 laptop
(13 items)
 
CPUMotherboardGraphicsRAM
Core i5 4690K ASRock Z97 Extreme4 XFX Radeon 7950 32 GB DDR3-2133 
Hard DriveOptical DriveCoolingOS
Samsung 850 EVO SSD Samsung DVD/CD-writer Corsair Hydro H60 Windows 7 
MonitorMonitorPowerCase
ASUS PA248Q Dell U2412M XFX 850W Black Edition XXX Fractal Design Arc Midi 2 
CPUMotherboardGraphicsRAM
Pentium Dual Core E6700 MSI G41M-P33 Combo ATI HD4350 Kingston ValueRAM DDR3-1333 
RAMHard DriveOSMonitor
Kingston ValueRAM DDR3-1333 WD Caviar Blue Windows 7 64-bit Sony 32" TV set 
Case
Apex TX-381 
CPUGraphicsRAMHard Drive
Core i5 430M GT230M (1 Gb dedicated) 8 GB DDR3-1066 640 GB 
OSMonitor
Windows 7 Home Premium (64-bit) 15.6" 
  hide details  
Reply
post #34 of 51
Quote:
Originally Posted by larsch View Post

You don't need visual basic to run vbscript. Windows can run it out of the box. But Jiiks' code you need to compile first :-)

Well it's easy to compile, just run 'path to .net framework/csc /out:"outputfile" "input file"'
Haswell
(21 items)
 
  
CPUMotherboardGraphicsRAM
Core i7 4770K @ 4Ghz Gigabyte Z87X-UD5H Sapphire Radeon R9 290 Vapor-X G.Skill RipjawsZ 4x4GB 2400Mhz 
Hard DriveHard DriveHard DriveHard Drive
Crucial M4 126GB Crucial MX100 4x512GB WD Caviar Green EZRX Crucial M500 120GB 
Optical DriveCoolingOSMonitor
Samsung DVD Corsair Hydro H105 Windows 7 Ultimate Acer B276HK 
MonitorMonitorKeyboardPower
Dell P2314H Samsung SA700 Logitech G710+ Seasonic P-660 XP2 
CaseMouseMouse PadAudio
Fractal Design Arc Midi R2 Razer Deathadder 2013 Mionix Sargas 900 Asus Xonar DX/XD 
Audio
Beyerdynamics Custome One Pro White 
  hide details  
Reply
Haswell
(21 items)
 
  
CPUMotherboardGraphicsRAM
Core i7 4770K @ 4Ghz Gigabyte Z87X-UD5H Sapphire Radeon R9 290 Vapor-X G.Skill RipjawsZ 4x4GB 2400Mhz 
Hard DriveHard DriveHard DriveHard Drive
Crucial M4 126GB Crucial MX100 4x512GB WD Caviar Green EZRX Crucial M500 120GB 
Optical DriveCoolingOSMonitor
Samsung DVD Corsair Hydro H105 Windows 7 Ultimate Acer B276HK 
MonitorMonitorKeyboardPower
Dell P2314H Samsung SA700 Logitech G710+ Seasonic P-660 XP2 
CaseMouseMouse PadAudio
Fractal Design Arc Midi R2 Razer Deathadder 2013 Mionix Sargas 900 Asus Xonar DX/XD 
Audio
Beyerdynamics Custome One Pro White 
  hide details  
Reply
post #35 of 51
Thread Starter 

Cool. I think I have the solution, thanks to larsch and also thanks to Quantum Reality for showing the screenshot of the Properties window (I did not know that I could put two different paths in the Target line). Here's what I did:

 

  1. I created the .vbs file
  2. Edited the shortcut properties of the pinned item on the Task bar (since shortcuts cannot be pinned)
  3. It works, of course. :)

 

So now, I'm going to do the same thing for the other pinned items that I sometimes open accidentally. lol This is a slick solution. I love it!

It's a computer!
(19 items)
 
  
CPUMotherboardGraphicsRAM
i5-2500K @ 4.5GHz (1.368-1.384V fixed voltage) ASUS P8P67 EVO B3 (UEFI ver. 1850) GTX 780 ASUS DirectCU II (1228 / 6300, 1.180V) G.SKILL Ripjaws X 8GB (2 x 4GB) 1866MHz, CL9 
Hard DriveHard DriveHard DriveOptical Drive
250 GB Samsung 840 EVO (C:\) 250 GB Samsung 840 EVO (D:\) 150 GB WD VelociRaptor Samsung SH-S243N 24x DVD Burner 
Optical DriveCoolingOSMonitor
Samsung SH-S203N 20X DVD Burner Thermaltake Frio Win 7 Home Premium x64 SP1 Retail AOC G2460PG (24" 1920 x 1080 144Hz G-SYNC) 
KeyboardPowerCaseMouse
Filco Majestouch 104-key Cherry MX Blues w/NKRO Corsair HX650 (Bronze, ordered on 12-12-2009) CM 690 Intellimouse Optical (1.1A) 1000Hz polling rate 
Mouse PadAudioAudio
Basic, but premium round X-Fi Titanium HD Klipsch ProMedia 2.1 (with 16 AWG Monster Cable... 
  hide details  
Reply
It's a computer!
(19 items)
 
  
CPUMotherboardGraphicsRAM
i5-2500K @ 4.5GHz (1.368-1.384V fixed voltage) ASUS P8P67 EVO B3 (UEFI ver. 1850) GTX 780 ASUS DirectCU II (1228 / 6300, 1.180V) G.SKILL Ripjaws X 8GB (2 x 4GB) 1866MHz, CL9 
Hard DriveHard DriveHard DriveOptical Drive
250 GB Samsung 840 EVO (C:\) 250 GB Samsung 840 EVO (D:\) 150 GB WD VelociRaptor Samsung SH-S243N 24x DVD Burner 
Optical DriveCoolingOSMonitor
Samsung SH-S203N 20X DVD Burner Thermaltake Frio Win 7 Home Premium x64 SP1 Retail AOC G2460PG (24" 1920 x 1080 144Hz G-SYNC) 
KeyboardPowerCaseMouse
Filco Majestouch 104-key Cherry MX Blues w/NKRO Corsair HX650 (Bronze, ordered on 12-12-2009) CM 690 Intellimouse Optical (1.1A) 1000Hz polling rate 
Mouse PadAudioAudio
Basic, but premium round X-Fi Titanium HD Klipsch ProMedia 2.1 (with 16 AWG Monster Cable... 
  hide details  
Reply
post #36 of 51
Quote:
Originally Posted by coachmark2 View Post

While not recommended for all programs, you could force the icons at the bottom of your screen to Run As Administrator every time. That would deliver a UAC prompt but would lead to some unnecessary privilege escalation....

Right click taskbar icon, right click the program name in the menu that appears, properties, compat. tab, checkbox for Run this Program as an Administrator

By far the easiest, just tried it out myself. Easy to implement for a bunch of programs as well.
Big Daddy
(18 items)
 
   
CPUMotherboardGraphicsRAM
Intel Core i5 3570K @ 4.5 GHz Gigabyte Z77X-UD3H EVGA 980 Ti Classified G Skill ripjaws x 16 GB 1866 
Hard DriveHard DriveCoolingOS
Seagate Barracuda 1 TB 7200 RPM Crucial MX 100 Corsair H80i GT Windows 7 Professional 64-bit 
MonitorMonitorKeyboardPower
Asus ROG Swift PG279Q Dell P170S KBP V80 TKL Seasonic X-750 
CaseMouseMouse PadAudio
Fractal Design Define R4 Titanium Grey Logitech G502 Razer Goliathus Speed M Creative Sound Blaster X-Fi Titanium 
AudioOther
AKG K7XX NZXT Mesh 5 Channel Fan Cantroller 
CPUGraphicsHard DriveCooling
Intel Core i7 2620M AMD Radeon HD 6470M Hitachi 320 GB 7200 rpm SED Stock, AC MX-4 
OSMonitorMouseMouse Pad
Windows 7 Professional 64 1600x900 Logitech G700 Razer Goliathus 
Audio
Onboard 
  hide details  
Reply
Big Daddy
(18 items)
 
   
CPUMotherboardGraphicsRAM
Intel Core i5 3570K @ 4.5 GHz Gigabyte Z77X-UD3H EVGA 980 Ti Classified G Skill ripjaws x 16 GB 1866 
Hard DriveHard DriveCoolingOS
Seagate Barracuda 1 TB 7200 RPM Crucial MX 100 Corsair H80i GT Windows 7 Professional 64-bit 
MonitorMonitorKeyboardPower
Asus ROG Swift PG279Q Dell P170S KBP V80 TKL Seasonic X-750 
CaseMouseMouse PadAudio
Fractal Design Define R4 Titanium Grey Logitech G502 Razer Goliathus Speed M Creative Sound Blaster X-Fi Titanium 
AudioOther
AKG K7XX NZXT Mesh 5 Channel Fan Cantroller 
CPUGraphicsHard DriveCooling
Intel Core i7 2620M AMD Radeon HD 6470M Hitachi 320 GB 7200 rpm SED Stock, AC MX-4 
OSMonitorMouseMouse Pad
Windows 7 Professional 64 1600x900 Logitech G700 Razer Goliathus 
Audio
Onboard 
  hide details  
Reply
post #37 of 51
Oo I like this.
post #38 of 51
Thread Starter 
Quote:
Originally Posted by MME1122 View Post


By far the easiest, just tried it out myself. Easy to implement for a bunch of programs as well.

 

But what I like about the .vbs script is this:

 

I can use the same script for all of my pinned items on the Taskbar. All I have to do is Shift + right click, choose Properties, and put the following line in front of what's there already, with a space after it:

 

"[put full path here]\Scriptname.vbs" (including the quotes)

 

I named mine "Confirm.vbs". hehe I also edited the MsgBox to "Do you really want to run this?":

 

cmd = ""
x = WScript.Arguments.Count - 1

For i=0 To x
        cmd = cmd + """" + WScript.Arguments(i) + """"
        If i < x Then cmd = cmd + " "
Next

result = MsgBox("Do you really want to open this?" + vbCrLf + vbCrLf + WScript.Arguments(0), VbYesNoCancel, "Run it?")

If result = vbYes Then WScript.CreateObject("WScript.Shell").Run cmd

 

Of course, I could make it say anything I want, including something hilarious, but I'm boring. :P

 

This is awesome. I'm glad that I didn't have to enable UAC.

It's a computer!
(19 items)
 
  
CPUMotherboardGraphicsRAM
i5-2500K @ 4.5GHz (1.368-1.384V fixed voltage) ASUS P8P67 EVO B3 (UEFI ver. 1850) GTX 780 ASUS DirectCU II (1228 / 6300, 1.180V) G.SKILL Ripjaws X 8GB (2 x 4GB) 1866MHz, CL9 
Hard DriveHard DriveHard DriveOptical Drive
250 GB Samsung 840 EVO (C:\) 250 GB Samsung 840 EVO (D:\) 150 GB WD VelociRaptor Samsung SH-S243N 24x DVD Burner 
Optical DriveCoolingOSMonitor
Samsung SH-S203N 20X DVD Burner Thermaltake Frio Win 7 Home Premium x64 SP1 Retail AOC G2460PG (24" 1920 x 1080 144Hz G-SYNC) 
KeyboardPowerCaseMouse
Filco Majestouch 104-key Cherry MX Blues w/NKRO Corsair HX650 (Bronze, ordered on 12-12-2009) CM 690 Intellimouse Optical (1.1A) 1000Hz polling rate 
Mouse PadAudioAudio
Basic, but premium round X-Fi Titanium HD Klipsch ProMedia 2.1 (with 16 AWG Monster Cable... 
  hide details  
Reply
It's a computer!
(19 items)
 
  
CPUMotherboardGraphicsRAM
i5-2500K @ 4.5GHz (1.368-1.384V fixed voltage) ASUS P8P67 EVO B3 (UEFI ver. 1850) GTX 780 ASUS DirectCU II (1228 / 6300, 1.180V) G.SKILL Ripjaws X 8GB (2 x 4GB) 1866MHz, CL9 
Hard DriveHard DriveHard DriveOptical Drive
250 GB Samsung 840 EVO (C:\) 250 GB Samsung 840 EVO (D:\) 150 GB WD VelociRaptor Samsung SH-S243N 24x DVD Burner 
Optical DriveCoolingOSMonitor
Samsung SH-S203N 20X DVD Burner Thermaltake Frio Win 7 Home Premium x64 SP1 Retail AOC G2460PG (24" 1920 x 1080 144Hz G-SYNC) 
KeyboardPowerCaseMouse
Filco Majestouch 104-key Cherry MX Blues w/NKRO Corsair HX650 (Bronze, ordered on 12-12-2009) CM 690 Intellimouse Optical (1.1A) 1000Hz polling rate 
Mouse PadAudioAudio
Basic, but premium round X-Fi Titanium HD Klipsch ProMedia 2.1 (with 16 AWG Monster Cable... 
  hide details  
Reply
post #39 of 51
You can change that "VbYesNoCancel" in the second to last line to "VbYesNo" and the dialog boxes won't have that cancel button anymore, just yes/no buttons.
post #40 of 51
Thread Starter 
Quote:
Originally Posted by deepor View Post

You can change that "VbYesNoCancel" in the second to last line to "VbYesNo" and the dialog boxes won't have that cancel button anymore, just yes/no buttons.

 

But having "Cancel" in the script (even if it's just YesCancel") enables me to press Esc, which I love. (Yeah, I can't get over how slick this is) If it's just YesNo, then I have to use my mouse to press No, or I have to press N, or maybe even Tab Enter. I'm very, very accustomed to pressing Esc for saying "No" or "Cancel".

 

However, I did just change it to OKCancel just because I can. I might change it to something else though just for fun. Not sure.


Edited by TwoCables - 3/15/14 at 12:36pm
It's a computer!
(19 items)
 
  
CPUMotherboardGraphicsRAM
i5-2500K @ 4.5GHz (1.368-1.384V fixed voltage) ASUS P8P67 EVO B3 (UEFI ver. 1850) GTX 780 ASUS DirectCU II (1228 / 6300, 1.180V) G.SKILL Ripjaws X 8GB (2 x 4GB) 1866MHz, CL9 
Hard DriveHard DriveHard DriveOptical Drive
250 GB Samsung 840 EVO (C:\) 250 GB Samsung 840 EVO (D:\) 150 GB WD VelociRaptor Samsung SH-S243N 24x DVD Burner 
Optical DriveCoolingOSMonitor
Samsung SH-S203N 20X DVD Burner Thermaltake Frio Win 7 Home Premium x64 SP1 Retail AOC G2460PG (24" 1920 x 1080 144Hz G-SYNC) 
KeyboardPowerCaseMouse
Filco Majestouch 104-key Cherry MX Blues w/NKRO Corsair HX650 (Bronze, ordered on 12-12-2009) CM 690 Intellimouse Optical (1.1A) 1000Hz polling rate 
Mouse PadAudioAudio
Basic, but premium round X-Fi Titanium HD Klipsch ProMedia 2.1 (with 16 AWG Monster Cable... 
  hide details  
Reply
It's a computer!
(19 items)
 
  
CPUMotherboardGraphicsRAM
i5-2500K @ 4.5GHz (1.368-1.384V fixed voltage) ASUS P8P67 EVO B3 (UEFI ver. 1850) GTX 780 ASUS DirectCU II (1228 / 6300, 1.180V) G.SKILL Ripjaws X 8GB (2 x 4GB) 1866MHz, CL9 
Hard DriveHard DriveHard DriveOptical Drive
250 GB Samsung 840 EVO (C:\) 250 GB Samsung 840 EVO (D:\) 150 GB WD VelociRaptor Samsung SH-S243N 24x DVD Burner 
Optical DriveCoolingOSMonitor
Samsung SH-S203N 20X DVD Burner Thermaltake Frio Win 7 Home Premium x64 SP1 Retail AOC G2460PG (24" 1920 x 1080 144Hz G-SYNC) 
KeyboardPowerCaseMouse
Filco Majestouch 104-key Cherry MX Blues w/NKRO Corsair HX650 (Bronze, ordered on 12-12-2009) CM 690 Intellimouse Optical (1.1A) 1000Hz polling rate 
Mouse PadAudioAudio
Basic, but premium round X-Fi Titanium HD Klipsch ProMedia 2.1 (with 16 AWG Monster Cable... 
  hide details  
Reply
New Posts  All Forums:Forum Nav:
  Return Home
  Back to Forum: Windows
Overclock.net › Forums › Software, Programming and Coding › Operating Systems › Windows › I want a message asking "Are you sure you want to open this?" for some programs.