Search Results

Search found 3341 results on 134 pages for 'prompt'.

Page 16/134 | < Previous Page | 12 13 14 15 16 17 18 19 20 21 22 23  | Next Page >

  • How to execute commands in Command Prompt using c#

    - by karthik
    I want to execute these steps in CMD using c# 1 - CD C:\MySQL\MySQL Server 5.0\bin 2 - mysqldump -uroot -ppassword sample d:\Test\222.sql On manually doing this, i will get file named "222.sql" I am using the below code to do it, but missing something.. Nothing Happens public void CreateScript_AAR() { string commandLine = @"CD C:\MySQL\MySQL Server 5.0\bin\mysqldump -uroot -ppassword sample> d:\Test\222.sql"""; System.Diagnostics.ProcessStartInfo PSI = new System.Diagnostics.ProcessStartInfo("cmd.exe"); PSI.RedirectStandardInput = true; PSI.RedirectStandardOutput = true; PSI.RedirectStandardError = true; PSI.UseShellExecute = false; System.Diagnostics.Process p = System.Diagnostics.Process.Start(PSI); System.IO.StreamWriter SW = p.StandardInput; System.IO.StreamReader SR = p.StandardOutput; SW.WriteLine(commandLine); SW.Close(); }

    Read the article

  • How to insert an integer into a database through command prompt

    - by jpavlov
    I am trying to insert a integer into a database in C# using the code below, but everytime I run the compiler informs me that my integer is not a valid column "Invalid Column Name UserID" Does anyone have any insight on this? Thanks. Console.WriteLine("Please enter a new User Id"); string line = Console.ReadLine(); int UserID; if (int.TryParse(line, out UserID)) { Console.WriteLine(UserID); Console.ReadLine(); } //Prepare the command string string insertString = @"INSERT INTO tb_User(ID,f_Name, l_Name) VALUES (UserID,'Ted','Turner')";

    Read the article

  • Install usb device without manager prompt

    - by Pat
    We have a usb device and the drivers (.inf, libusb.dll, libusb.sys) and can install it using Windows' Device Installation Wizard (by pointing to the .inf file). However, we need to install the drivers without using the wizard (passively, so the user doesn't need to do anything). Does anyone know how this can be achieved?

    Read the article

  • CMD Prompt > FTP Size Command

    - by Samuel Baldus
    I'm developing a PHP App on IIS 7.5, which uses PHP FTP commands. These all work, apart from ftp_size(). I've tested: cmd.exe > ftp host > username > password > SIZE filename = Invalid Command However, if I access the FTP site through an Internet Browser, the filesize is displayed. Do I need to install FTP Extensions, and if so, which ones and where do I get them? Here is the PHP Code: <?php // FTP Credentials $ftpServer = "www.domain.com"; $ftpUser = "username"; $ftpPass = "password"; // Unlimited Time set_time_limit(0); // Connect to FTP Server $conn = @ftp_connect($ftpServer) or die("Couldn't connect to FTP server"); // Login to FTP Site $login = @ftp_login($conn, $ftpUser, $ftpPass) or die("Login credentials were rejected"); // Set FTP Passive Mode = True ftp_pasv ($conn, true); // Build the file list $ftp_nlist = ftp_nlist($conn, "."); // Alphabetical sorting sort($ftp_nlist); // Display Output foreach ($ftp_nlist as $raw_file) { // Get the last modified time $mod = ftp_mdtm($conn, $raw_file); // Get the file size $size = ftp_size($conn, $raw_file); // Size is not '-1' => file if (!(ftp_size($conn, $raw_file) == -1)) { //output as file echo "Filename: $raw_file<br />"; echo "FileSize: ".number_format($size, '')."Kb</br>"; echo "Last Modified: ".date("d/m/Y H:i", $mod)."</br>"; } } ?>

    Read the article

  • How to prompt for input using an existing variable in the prompt.

    - by ldigas
    I'm trying to ask the user for a value of some variable, but at the same time, showing him the last value used (at the termination of the program, the values are saved to a file, and loaded at the start of the program). Something like this: Enter new radius value (R=12.6) : ... user enters 12.7 ... Enter new pi value (pi=3.14) : Enter new height value (h=30.0) : Usually I would write the first one with write statement, then read the new one (in Fortran, for example). In MATLAB however, I don't know how to write something out with input statement. Are there some other statements for getting input ?

    Read the article

  • How to prompt user input parameters for SQL Queries in Access 2010

    - by user1848907
    SELECT Transactions.TransactionNumber FROM Transactions WHERE (((Transactions.Date)>=#11/23/12#)) AND (((Transactions.Date)<=#11/23/12#)); The above code returns all the transaction that happened between the specified dates. But I want those dates to be defined by the user every time the query is executed. I tried using the [] operators to have the user define the criteria in the WHERE, something like this: WHERE (((Transactions.Date)>=[Input a Date])) AND (((Transactions.Date)<=[Input a Date])); But microsoft Access throws a Syntax error message. The same happens when I include the # (date operators) like this WHERE (((Transactions.Date)>=#[Input a Date]#)) AND (((Transactions.Date)<=#[Input a Date]#)); Is there anopther way to manage dates that I'm not aware of or is asking a user for dates in a query out of the question

    Read the article

  • Why does Application.Exit Prompt me twice?

    - by Michael Quiles
    How can I stop the message box from showing up twice when I press the X on the form ? FYI the butoon click works fine it's the X that prompts me twice. private void xGameForm_FormClosing(object sender, FormClosingEventArgs e) { //Yes or no message box to exit the application DialogResult Response; Response = MessageBox.Show("Are you sure you want to Exit?", "Exit", MessageBoxButtons.YesNo, MessageBoxIcon.Question, MessageBoxDefaultButton.Button2); if (Response == DialogResult.Yes) Application.Exit(); } public void button1_Click(object sender, EventArgs e) { Application.Exit(); }

    Read the article

  • How to automate rsync without asking for password prompt

    - by Rijosh K
    i would like to automate the rsync task as a cron job.. since it needs the passphrase i am not able to do the cronjob. i need to specify the passphrase along with the rsync command or i will store the passphrase in a file and i will read from it. my command will look like this.. rsync -aPe "ssh -i ' . $server-{'ssh_key'} . '" ' . $server_lock_dir; so where do i put the password .. pls help

    Read the article

  • Writing a script with the cmd prompt.

    - by Josh
    I'm trying to make a script that will place a list (in a .csv file) of processes that are running that take up more than 10 mb of RAM and shows the time + date the script was run. My teacher did this during his lecture but I can't remember how he did it. Just trying to figure out how to be better at IT. So my question is, can anyone help me with this? I don't even know where to start.

    Read the article

  • iOS - Prompt User to Update to Latest App Version

    - by Kevin_TA
    Is there any method or plugin available that will alert the user to upgrade an app if the version they are using is not the latest? I suppose I could ping a web service to check what the current version is and compare with the user's version and go from there. As an aside, is there a way to check the current version of the app (some property I don't know about) or do you simply have to hardcode the version as some float variable or something? Thanks

    Read the article

  • How come Win+R prompt can open Python when it's not in my path?

    - by houbysoft
    When I use the run prompt in Windows XP Professional (Win+R), and type python.exe or python, it works and greets me with the python prompt. However, when I start a cmd window, and then type python.exe or python, it doesn't find it. This is what I expect, as the Python directory (for me, I:\Python31\) is not in my PATH. How come, then, that if I type python.exe in the Win+R prompt, it works? Edit: here is a partial output of SET, I removed most irrelevant entries, I'm not sure why is it useful, apart from the PATH variable which I already said doesn't include the Python directory. If you need a particular variable other than these, please ask. CLIENTNAME=Console CommonProgramFiles=I:\Program Files\Common Files ComSpec=I:\WINDOWS\system32\cmd.exe FP_NO_HOST_CHECK=NO OS=Windows_NT Path=I:\WINDOWS\system32;I:\WINDOWS;I:\WINDOWS\system32\WBEM;I:\WINDOWS\system32\WindowsPowerShell\v1.0;I:\Qt\2010.05\mingw\bin;I:\Program Files\CMake 2.8\bin PATHEXT=.COM;.EXE;.BAT;.CMD;.VBS;.VBE;.JS;.JSE;.WSF;.WSH;.PSC1 ProgramFiles=I:\Program Files PROMPT=$P$G SESSIONNAME=Console SystemDrive=I: SystemRoot=I:\WINDOWS VBOX_INSTALL_PATH=I:\Program Files\Oracle\VirtualBox\ windir=I:\WINDOWS

    Read the article

  • Why doesn't the Windows command prompt window maximize to the full screen size?

    - by Antoni
    Anyone know why doesn't the Windows command prompt window maximize to the full screen size? To the best of my knowledge, even in the new Windows 7 the command prompt window(cmd.exe) doesn't maximize to the full screen size like all other windows. This behavior is quite annoying for me, and I'm sure to many others as well. Note: The size of the command prompt window can be changed, but the size remains fixed regardless of the screen size.

    Read the article

  • How can I prompt user for additional permissions on page load?

    - by Rew
    Note: The application I'm building is a website type Facebook Application that uses Facebook Connect. I can prompt the user with a request for Extended Permissions using the following FBML code: <fb:prompt-permission perms="read_stream,publish_stream"> Grant permission for status updates </fb:prompt-permission> Taken from here. This creates a link on the page that must be clicked by the user in order to trigger the prompt to display. My question is: Is it possible to display this prompt automatically, when the page loads, without requiring the user to click on the link? Also, in reply to the answer below, I'd like to avoid displaying the link. Would prefer a neat way to do this, if that fails the least dirty method will do :-)

    Read the article

  • How to structure reading of commands given at a(n interactive) CLI prompt?

    - by Anto
    Let's say I have a program called theprogram (the marketing team was on strike when the product was to be named). I start that program by typing, perhaps not surprisingly, the program name as a command into a command prompt. After that, I get into a loop (from the users standpoint, an interactive command-line prompt), where one command will be read from the user, and depending on what command was given, the program will execute some instructions. I have been doing something like the following (in C-like pseudocode): main_loop{ in=read_input(); if(in=="command 1") do_something(); else if(in=="command 2") do_something_else(); ... } (In a real program, I would probably encapsulate more things into different procedures, this is just an example.) This works well for a small amount of commands, but let's say you have 100, 1000 or even 10 000 of them (the manual would be huge!). It is clearly a bad idea to have 10 000 ifs and else ifs after each other, for instance, the program would be hard to read, hard to maintain, contain a lot of boilerplate code... Yeah, you don't want to do that, so what approach would you recommend me to use (I will probably never use 10 000 commands in a program, but the solution should, at least preferably, be able to scale to that kind of massive (?) problems. The solution doesn't have to allow for arguments to the commands)?

    Read the article

  • How to make Windows command prompt treat single quote as though it is a double quote?

    - by mark
    My scenario is simple - I am copying script samples from the Mercurial online book (at http://hGBook.red-bean.com) and pasting them in a Windows command prompt. The problem is that the samples in the book use single quoted strings. When a single quoted string is passed on the Windows command prompt, the latter does not recognize that everything between the single quotes belongs to one string. For example, the following command: hg commit -m 'Initial commit' cannot be pasted as is in a command prompt, because the latter treats 'Initial commit' as two strings - 'Initial and commit'. I have to edit the command after paste and it is annoying. Is it possible to instruct the Windows command prompt to treat single quotes similarly to the double one? EDIT Following the reply by JdeBP I have done a little research. Here is the summary: Mercurial entry point looks like so (it is a python program): def run(): "run the command in sys.argv" sys.exit(dispatch(request(sys.argv[1:]))) So, I have created a tiny python program to mimic the command line processing used by mercurial: import sys print sys.argv[1:] Here is the Unix console log: [hg@Quake ~]$ python 1.py "1 2 3" ['1 2 3'] [hg@Quake ~]$ python 1.py '1 2 3' ['1 2 3'] [hg@Quake ~]$ python 1.py 1 2 3 ['1', '2', '3'] [hg@Quake ~]$ And here is the respective Windows console log: C:\Workpython 1.py "1 2 3" ['1 2 3'] C:\Workpython 1.py '1 2 3' ["'1", '2', "3'"] C:\Workpython 1.py 1 2 3 ['1', '2', '3'] C:\Work One can clearly see that Windows does not treat single quotes as double quotes. And this is the essence of my question.

    Read the article

  • Html5: How to handle RGB pixel with commands from prompt ? (just a browser)

    - by Rocket Surgeon
    In the browser tools, say in debugging (any browser will do, but IE9 preferred) how can I access things like html5 canvas and modify individual pixels by typing commands from prompt ? I know, it is possible to accomplish in miriad normal ways with preparing the markup and loading the page, but what is the shortest path ? The browser is running with some content, then I hit F12-Console- what exactly should I type to cause a canvas to change ? Thank you

    Read the article

  • Is Cygwin or Windows Command Prompt preferable for getting a consistent terminal experience for development?

    - by Paul Hazen
    The question: Which is better, installing cygwin or one of its cousins on all my windows machines to have a consistent terminal experience across all my development machines, or becoming well trained in the skill of mentally switching from linux terminal to windows command prompt? Systems I use: OSX Lion on a Macbook Air Windows 8 on a desktop Windows 7 on the same desktop Fedora 16 on the same desktop What I'm trying to accomplish Configure an entirely consistent (or consistent enough) terminal experience across all my machines. "enough" in this context is clearly subjective. Please be clear in your answer why the configuration you suggest is consistent enough. One more thing to keep in mind: While I do write a lot of code intended to run on Windows (actually code that runs on Windows Phone which necessitates a windows machine), I also write a lot of Java code, and prefer to do so in vim. I test a local repo in Java on my windows machine, and push to another test machine running ubuntu later in the development stage. When I push to the ubuntu machine, I'm exclusively in terminal, since I'm accessing it via SSH. Summary, with more accurate question: Is there a good way to accomplish what I'm trying to do, or is it better to get accustomed to remembering different commands based on the system I'm on? Which (if either) is considered "best practice" by the development community? Alternatively, for a consistent development experience, would it be better to write all my code SSHed into another machine, and move things to windows for compile / build only when I needed to? That seems like too much work... but could be a solution. Update: While there are insightful responses below, I have yet to hear an answer that talks about why any given solution is superior. Cygwin/GnuWin32 is certainly a way to accomplish a similar experience on all platforms, but since I'm just learning all things command line, I don't want to set myself up to do a lot of relearning/unlearning in the future. Cygwin/GnuWin32 has its peculiarities I would imagine, and being aware of how that set up works on Windows is a learning curve. Additionally, using Cygwin/GnuWin32 robs me of learning the benefits of PowerShell. As a newcomer to working in a command line, which path should I choose to minimize having to relearn/unlearn things in the future? or as my first paragraph poses: [is it better to use Cygwin] ...or [become] well trained in the skill of mentally switching from linux terminal to windows command prompt?

    Read the article

  • Windows 7, how to get unlock (Press Ctrl+Alt+del) prompt on all monitors?

    - by Zugwalt
    I have a laptop that I keep shut in a docking station as I have two screens connected to the laptop and it cannot display to both of those AND its own screen. However, when my computer locks by itself (Not when I lock it using Ctrl+Alt+Del) the login prompt is ONLY on it screen (at least its there when I open it up) and my primary external monitor is off and my other one is all black. This means to log in I have to hit Ctrl+Alt+Del and blindly enter my password--which I don't mind too much, but would prefer if I could actually see the unlock/login prompt instead of typing on a black screen. Any way to have it show the login prompt on all monitors?

    Read the article

  • How to set a PHP session variable through linux command prompt?

    - by Sev
    How to set a PHP session variable through linux command prompt? Clarification So, as you know we can set session variables in PHP using $_SESSION global variable when coding. I would like to know if there is a way to set this variable through php command prompt? For example, in the code, if I can set $_SESSION['temp'] = "whatever" Is there a way to set the same variable through command prompt PHP?

    Read the article

  • What's the difference between the ruby irb prompt modes?

    - by Steven
    I can change the irb prompt mode with irb --prompt prompt-mode I can see what null and simple does, but I can't tell the difference between null and xmp and the difference between default/classic/inf-ruby. Can someone explain to me what these other modes do? It seems pointless to have multiple modes doing the same thing.

    Read the article

  • Xfce session will not login from login prompt. Why?

    - by hydroparadise
    Well, not sure how I did it, but for some reason I am unable to get past the login screen on Xfce. What's odd is that I had set the machine up (from install) to login automatically. Then when I finish rebooting after installing sudo apt-get install openssh-server and sudo apt-get install vnc4server all the sudden I am getting prompted for my password. I proceed to type my password (successfully might I add) to login, the screen goes black for a second, then brings me right back to the same password prompt. I am able ssh in(now), but I get no love from workstation login. Maybe vnc4server is the culprit? What did I do? And can I fix it? EDIT: The guest account, however will let me login no problem. What gives? I have a sneaking feeling that this could be permission issue.

    Read the article

  • Disk drive won't let go of password prompt at bootup?

    - by user54003
    I had a hacker intrude into my system, at the time it was obvious, so I reinstalled. However, I am left with what appears to be a fatal problem as far as one of my disk drives goes. When I install that drive in my system, a prompt comes up for the disk password, and what it is asking for is a root password. The disk works otherwise normally but despite all my efforts, I have not been able to fix this disk. I have gotten the operating system parted magic and done the most extreme clean up available, the internal one which sends a signal to the disk electronics which runs a built in clean up program. Darik's boot and nuke, I've tried them all but I can't seem to remove this with anything in the Linux line. Does anyone have any suggestions? I've run gparted, created a Sun, an Apple and various other schemes to partition the disk, all to no avail. Can anyone help?

    Read the article

< Previous Page | 12 13 14 15 16 17 18 19 20 21 22 23  | Next Page >