Search Results

Search found 28350 results on 1134 pages for 'command switch'.

Page 43/1134 | < Previous Page | 39 40 41 42 43 44 45 46 47 48 49 50  | Next Page >

  • How to keep Ubuntu 11.10 and Kate editor w/terminal from changing command line when changing tabs?

    - by Kairan
    I am programming C using Kate editor in Ubuntu 11.10. It works great, but when I change tabs in Kate, the terminal line changes to the file path of the tab I click on. Normally this is not a big deal (other than annoyingly adding extra text to my terminal) however if I am currently RUNNNING a C program, it obviously will type at the command line, which is not so cool. Example terminal window for my C program (its at a menu): 1) select opt 1 2) select opt 2 Enter choice: (here it waits for prompt from user) Now when I click a tab in Kate, it wants to put in the cd / path of the file in that tab, such as: cd /home/user/os/files And of course since my terminal was waiting for prompt from user it gets that command.. not good. Perhaps there is no fix, but maybe someone knows? Obviously I could choose NOT to switch tabs or end program before switching tabs... Note: I probably made the mistake of putting this under StackOverflow which is more of a programming area - so though repost here might be best (I am not sure how to link the questions but will paste hyperlink to that post - I dont want to violate any stackoverflow/superuser violations) Suggestions on merging them are welcome or if I should delete one? StackOverFlow Question

    Read the article

  • How can I both pipe and display output in Windows' command line?

    - by Bob
    I have a process I need to run within a batch file. This process produces some output. I need to both display this output to the screen and send (pipe) it to another program. The bash method uses tee: echo 'ee' | tee /dev/tty | foo Is there an equivalent for Windows? I am happy to use PowerShell if necessary. There are tee ports for Windows, but there does not appear to be an equivalent for /dev/tty, which complicates matters. The specific use-case here: I have a program (launch4j) that I need to run, displaying output to the user. At the same time, I need to be able to detect success or failure in the script. Unfortunately, this program does not set an exit code, and I cannot force it to do so. My current workaround involves piping to find, to search the output (launch4j config.xml | find "Successfully created") - however, that swallows the output I need to display. Therefore, I need some way to both display to the screen and send the ouput to a command - and this command should be able to set ERRORLEVEL (it cannot run asynchronously).

    Read the article

  • Can i use a switch to hold a function?

    - by TIMOTHY
    I have a 3 file program, basically teaching myself c++. I have an issue. I made a switch to use the math function. I need and put it in a variable, but for some reason I get a zero as a result. Also another issue, when I select 4 (divide) it crashes... Is there a reason? Main file: #include <iostream> #include "math.h" #include <string> using namespace std; int opersel; int c; int a; int b; string test; int main(){ cout << "Welcome to Math-matrix v.34"<< endl; cout << "Shall we begin?" <<endl; //ASK USER IF THEY ARE READY TO BEGIN string answer; cin >> answer; if(answer == "yes" || answer == "YES" || answer == "Yes") { cout << "excellent lets begin..." << endl; cout << "please select a operator..." << endl << endl; cout << "(1) + " << endl; cout << "(2) - " << endl; cout << "(3) * " << endl; cout << "(4) / " << endl; cin >> opersel; switch(opersel){ case 1: c = add(a,b); break; case 2: c = sub(a,b); break; case 3: c = multi(a,b); break; case 4: c = divide(a,b); break; default: cout << "error... retry" << endl; }// end retry cout << "alright, how please select first digit?" << endl; cin >> a; cout << "excellent... and your second?" << endl; cin >> b; cout << c; cin >> test; }else if (answer == "no" || answer == "NO" || answer == "No"){ }//GAME ENDS }// end of int main Here is my math.h file #ifndef MATH_H #define MATH_H int add(int a, int b); int sub(int a, int b); int multi(int a, int b); int divide(int a, int b); #endif Here is my math.cpp: int add(int a, int b) { return a + b; } int sub(int a, int b) { return a - b; } int multi(int a, int b) { return a * b; } int divide(int a, int b) { return a / b; } }// end of int main

    Read the article

  • ESXI 5.1 - Unable to trunk to cisco switch

    - by Lance
    I have configured my esxi host vSwitch1 to use the secondary NIC on my VMware host. On vSwitch1 configuration I have set the VLAN to 4095 which specifies to allow all VLANs. If my cisco switch port configuration is set to an access port my server can ping the vlan interface on the switch. If my cisco switch port configuration is set to a trunk, whilst it stays UP UP and CDP information is available, I lose my ping from VMware VM server to the local vlan interface on the switch and I lose any server connectivity to my network. Switch NIC teaming policy to Route based on originating virtual port ID Configuration based on: http://kb.vmware.com/selfservice/microsites/search.do?language=en_US&cmd=displayKC&externalId=1006628 interface GigabitEthernet0/42 description Host Port switchport trunk encapsulation dot1q switchport trunk allowed vlan 18,220 switchport mode trunk switchport nonegotiate spanning-tree portfast trunk end Output from ESXI CLI esxcfg-vswitch -l: ~ # esxcfg-vswitch -l Switch Name Num Ports Used Ports Configured Ports MTU Uplinks vSwitch0 128 5 128 1500 vmnic0 PortGroup Name VLAN ID Used Ports Uplinks VM Network 4095 1 vmnic0 Management Network 4095 1 vmnic0 Switch Name Num Ports Used Ports Configured Ports MTU Uplinks vSwitch1 128 4 128 1500 vmnic1 PortGroup Name VLAN ID Used Ports Uplinks VM Network 2 4095 1 vmnic1 Any tips welcome!!!

    Read the article

  • DBA Command line options

    - by Anthony Shorten
    There are a number of database utilities supplied with the installation of the Oracle Utilities Application Framework based products. These are typically run in interactive mode where the utility prompts you for the values and then executes the required functionality. Did you know that the utilities also have command line options that allow you to run the utility in silent mode as well? You can assess the command line options by specifying the -h option on the command line. Here is an example of the oragensec command line options: oragensec -d <Owner,OwnerPswd,DbName> -u <Database Users> -r <ReadRole,UserRole> -l <logfile> -h where: -d <Owner,OwnerPswd,DbName> Database connect information for the target database. e.g. spladm,spladm,DB200ODB. -u <Database Users> A comma-separated list of database users where synonyms need to be created. e.g. spluser, splread -r <ReadRole,UserRole> Optional. Names of database roles with read and read-write privileges. Default roles are SPL_READ, SPL_USER. e.g. spl_read,spl_user -l <logfile> Optional. Name of the log file. -h Help The command line options allow the DBA to automate the exeucution either via a script or some utility can than execute utilities. This optin can apply to the majority of DBA utilities supplied with the product. Take a look at others.

    Read the article

  • Building/Installing Required a52 Plugin

    - by user71139
    I am trying to compile and install the a52 plugin following the instructions from here: https://help.ubuntu.com/community/DigitalAC-3Pulseaudio This worked on Ubuntu 11.10 but gives me some errors when I try to compile the plugin on Ubuntu 12.04. I've searched for a solution however I couldn't find much on this topic in general, not to talk about a solution. I would really appreciate some help on this: bogdan@bogdan-desktop:~$ cd ~/tmp/ bogdan@bogdan-desktop:~/tmp$ cd alsa-plugins-1.0.25/ bogdan@bogdan-desktop:~/tmp/alsa-plugins-1.0.25$ make make all-recursive make[1]: Entering directory `/home/bogdan/tmp/alsa-plugins-1.0.25' Making all in oss make[2]: Entering directory `/home/bogdan/tmp/alsa-plugins-1.0.25/oss' /bin/bash ../libtool --tag=CC --mode=compile gcc -DHAVE_CONFIG_H -I. -I.. -Wall -g -I/usr/include/alsa -g -O2 -MT ctl_oss.lo -MD -MP -MF .deps/ctl_oss.Tpo -c -o ctl_oss.lo ctl_oss.c ../libtool: line 831: X--tag=CC: command not found ../libtool: line 864: libtool: ignoring unknown tag : command not found ../libtool: line 831: X--mode=compile: command not found ../libtool: line 997: *** Warning: inferring the mode of operation is deprecated.: command not found ../libtool: line 998: *** Future versions of Libtool will require --mode=MODE be specified.: command not found ../libtool: line 1141: Xgcc: command not found ../libtool: line 1141: X-DHAVE_CONFIG_H: command not found ../libtool: line 1141: X-I.: command not found ../libtool: line 1141: X-I..: command not found ../libtool: line 1141: X-Wall: command not found ../libtool: line 1141: X-g: command not found ../libtool: line 1141: X-I/usr/include/alsa: No such file or directory ../libtool: line 1141: X-g: command not found ../libtool: line 1141: X-O2: command not found ../libtool: line 1141: X-MT: command not found ../libtool: line 1141: Xctl_oss.lo: command not found ../libtool: line 1141: X-MD: command not found ../libtool: line 1141: X-MP: command not found ../libtool: line 1141: X-MF: command not found ../libtool: line 1141: X.deps/ctl_oss.Tpo: No such file or directory ../libtool: line 1141: X-c: command not found ../libtool: line 1192: Xctl_oss.lo: command not found ../libtool: line 1197: libtool: compile: cannot determine name of library object from `': command not found make[2]: *** [ctl_oss.lo] Error 1 make[2]: Leaving directory `/home/bogdan/tmp/alsa-plugins-1.0.25/oss' make[1]: *** [all-recursive] Error 1 make[1]: Leaving directory `/home/bogdan/tmp/alsa-plugins-1.0.25' make: *** [all] Error 2 bogdan@bogdan-desktop:~/tmp/alsa-plugins-1.0.25$

    Read the article

  • Switch Gmail Icons Back to Text Labels

    - by Jason Fitzpatrick
    If Gmail’s icon-based buttons annoy you, it’s now possible to switch them back to the old text labels with a simple settings toggle. At MakeUseOf they highlight the new option in Gmail and how you can switch back to the old button layout: So how do you make that happen? All you have to do is click on the cog button, choose “Settings”, and go to the the General tab. Scroll down to find the “Button labels” setting, and change it from icons to text. I know what I’ll be doing shortly; text-based button labels here I come. [via MakeUseOf] Make Your Own Windows 8 Start Button with Zero Memory Usage Reader Request: How To Repair Blurry Photos HTG Explains: What Can You Find in an Email Header?

    Read the article

  • How disable mysql command in sudoers file?

    - by Carlos A. Junior
    How i can disable /usr/bin/mysql command in sudoers file ? ... Actually I've tryed use with this way: %tailonly ALL=!/usr/bin/mysql But when i'm access if user 'tailonly' of group 'tailonly', this command still enabled. In resume, i'm only want that 'tailonly' user access 'tail -f /usr/app/*.log' ... This is possible ? Edit: With this config, the user 'tailonly' still can access mysql terminal with 'mysql' command: $: sudo su $: visudo Cmnd_Alias MYSQL = /usr/bin/mysql Cmnd_Alias TAIL=/usr/bin/tail -f /jacad/jacad3/logs/*.log # User privilege specification root ALL=(ALL:ALL) ALL # Members of the admin group may gain root privileges %admin ALL=(ALL) ALL # Allow members of group sudo to execute any command %sudo ALL=(ALL:ALL) ALL %swa ALL=/etc/init.d/jacad3 stop %swa ALL=/etc/init.d/jacad3 start %swa ALL=/etc/init.d/jacad3 restart %swa ALL=sudoedit /jacad/jacad3/bin/jacad_start.sh %tailonly ALL=ALL,!MYSQL

    Read the article

  • JDeveloper 11.1.2 : Command Link in Table Column Work Around

    - by Frank Nimphius
    Just figured that in Oracle JDeveloper 11.1.2, clicking on a command link in a table does not mark the table row as selected as it is the behavior in previous releases of Oracle JDeveloper. For the time being, the following work around can be used to achieve the "old" behavior: To mark the table row as selected, you need to build and queue the table selection event in the code executed by the command link action listener. To queue a selection event, you need to know about the rowKey of the row that the command link that you clicked on is located in. To get to this information, you add an f:attribute tag to the command link as shown below <af:column sortProperty="#{bindings.DepartmentsView1.hints.DepartmentId.name}" sortable="false"    headerText="#{bindings.DepartmentsView1.hints.DepartmentId.label}" id="c1">   <af:commandLink text="#{row.DepartmentId}" id="cl1" partialSubmit="true"       actionListener="#{BrowseBean.onCommandItemSelected}">     <f:attribute name="rowKey" value="#{row.rowKey}"/>   </af:commandLink>   ... </af:column> The f:attribute tag references #{row.rowKey} wich in ADF translates to JUCtrlHierNodeBinding.getRowKey(). This information can be used in the command link action listener to compose the RowKeySet you need to queue the selected row. For simplicitly reasons, I created a table "binding" reference to the managed bean that executes the command link action. The managed bean code that is referenced from the af:commandLink actionListener property is shown next: public void onCommandItemSelected(ActionEvent actionEvent) {   //get access to the clicked command link   RichCommandLink comp = (RichCommandLink)actionEvent.getComponent();   //read the added f:attribute value   Key rowKey = (Key) comp.getAttributes().get("rowKey");     //get the current selected RowKeySet from the table   RowKeySet oldSelection = table.getSelectedRowKeys();   //build an empty RowKeySet for the new selection   RowKeySetImpl newSelection = new RowKeySetImpl();     //RowKeySets contain List objects with key objects in them   ArrayList list = new ArrayList();   list.add(rowKey);   newSelection.add(list);     //create the selectionEvent and queue it   SelectionEvent selectionEvent = new SelectionEvent(oldSelection, newSelection, table);   selectionEvent.queue();     //refresh the table   AdfFacesContext.getCurrentInstance().addPartialTarget(table); }

    Read the article

  • Sound fails when I switch users

    - by Sam
    Sound on my computer was working fine under 12.04 however when I upgraded to 12.10 I have encounter a strange problem where when I switch users instead of the first user having its sound swamped the sound of the first user keep playing and the second user can not play and thing. The sound setting for the second user only show a Dummy Output. If I reboot and log into the second user sound works fine but then if you switch to the first user it has a dummy output instead. What could would cause such a problem?

    Read the article

  • Make the Taskbar Buttons Switch to the Last Active Window in Windows 7

    - by The Geek
    The new Windows 7 taskbar’s Aero Peek feature, with the live thumbnails of every window, is awesome… but sometimes you just want to be able to click the taskbar button and have the last open window show up instead. Here’s a quick hack to make it work better. To better understand the problem, imagine having nine windows of the same type open on your screen, but you are primarily working in just one of the windows at a time. So every time you want to switch back, you have to click the taskbar button, and then choose the one you are using from the list, which can be pretty annoying… Now if you know your Windows 7 shortcuts, you’d know that you can simply hold down the Ctrl key while clicking on the taskbar button, and the last window will show up. In fact, you can keep holding down the Ctrl key and keep clicking, and Windows will cycle through the open windows. It’s a useful shortcut, but hardly something you want to do every single time. Instead, we’ll use a quick registry hack to make the normal click switch to the last open window—if you still want to see the thumbnail list, just hover your mouse over the button for half a second to see the full list. Manual Registry Hack for Last Active Window Open up regedit.exe through the start menu search or run box, and then head down to the following registry key: HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced Once you’re there, create a new 32-bit DWORD value on the right hand side, give it the name LastActiveClick, and set the value to 1. Once you are done, it should look something like this: Once you are done, you’ll have to log off and back on, or you can kill Explorer.exe through Task Manager and re-open it. Download the Registry Hack Instead Since you probably don’t feel like registry hacking, we’ve provided you an easy downloadable version. You can simply download the file, extract it, and then double-click on the LastActiveClick.reg file. Once you are done, you’ll have to log off and back on, just like with the manual registry hack. Download LastActiveClick Registry Hack from howtogeek.com Similar Articles Productive Geek Tips Make the Windows 7 Taskbar Work More Like Windows XP or VistaStupid Geek Tricks: Select Multiple Windows on the TaskbarReorganize Your Taskbar Buttons and Tray Icons in XP/VistaKeyboard Ninja: Create a Hotkey to Switch to Your Open Outlook WindowTaskbar Eliminator Does What the Name Implies: Hides Your Windows Taskbar TouchFreeze Alternative in AutoHotkey The Icy Undertow Desktop Windows Home Server – Backup to LAN The Clear & Clean Desktop Use This Bookmarklet to Easily Get Albums Use AutoHotkey to Assign a Hotkey to a Specific Window Latest Software Reviews Tinyhacker Random Tips DVDFab 6 Revo Uninstaller Pro Registry Mechanic 9 for Windows PC Tools Internet Security Suite 2010 Gadfly is a cool Twitter/Silverlight app Enable DreamScene in Windows 7 Microsoft’s “How Do I ?” Videos Home Networks – How do they look like & the problems they cause Check Your IMAP Mail Offline In Thunderbird Follow Finder Finds You Twitter Users To Follow

    Read the article

  • run a script on window switch (on alt-tabbing into/outof a particular app)

    - by hwjp
    I'd like to run a script whenever I switch into or out of a window. Specifically, I have a "toggle touchpad on/off" script, which i want to run whenever I switch into or out of gvim. so, is there any kind of hook for that? even something that can be run whenever alt-tab is detected, as long as it can tell what window you're going from/to? I'm using gnome-shell, if that makes any difference. [edit] Have started looking into gnome-shell-extensions, which seem to be written in javascript, so might not be too hard to hack one together myself...

    Read the article

  • Cannot login to newly created user account

    - by penner
    Trying to switch accounts to my newly created account I get a black screen and then it takes me back to the main login screen after entering the correct password. Upon logging into my previously existing account I get: "System Program Problem Detected" Details: Executable path /usr/bin/Xorg Package: xserver-xorg-core 2:1.11.4-0ubuntu10.1 Details: Crash ... (tons more, but no way to copy paste or save) When I try to su su -l penner I get: No directory, logging in with HOME=/ I manually created the home directory and this error goes away but still no luck with the login. Seems something has gone wrong with the user creation? How can I correct this?

    Read the article

  • Rhythmbox in Unity: sometimes cannot access GUI if run from command line, no command line support for .m3u/ .pls

    - by Cee
    I previously was using Rhythmbox in 10.04 and recently installed it (version 2.90.1) in my system now running 11.10. I've discovered the following issues: Sometimes if I start Rhythmbox from the command line e.g. rhythmbox [uri of radio station], the GUI does not appear although I get the audio stream and I am not able to access the GUI when I click on the icon in the Unity launcher. Previously in 10.04, I was able to access the GUI after starting from command line by clicking the icon in the notification tray but it no longer appears there. Sometimes after running Rhythmbox from command line, when I click on the icon in the Unity launcher the GUI does not appear (even though I am clicking with the middle button on my mouse) and an icon-sized space appears under the Rhythmbox icon in the launcher. When I right click this space, I get a menu with a blank line followed by "Keep in launcher". Although I can play the uri's linking to .m3u and .pls files for radio streams in the GUI, they do not work in the command line. Instead I have to download the .m3u & .pls files to get the uri inside those files and use that as the argument instead when running from command line. Is there any way to fix these issues?

    Read the article

  • Is it possible to save output from a command to a file after the command already has been executed?

    - by NES
    Does an elegant way exist to save the output of a command to a file after the command has been run, with the terminal window is open? I mean once the command has been executed in the terminal. The output is still there in terminal. Now i could copy & paste all the lines and save it to a file. But perhaps does a method exist to somehow write the output buffer of a terminal window to a file or even better the output of an already executed command?

    Read the article

  • C# output of running command prompt

    - by Kaushal Singh
    In this following code whenever I send any command like dir or anything this function get stuck in while loop... I want the output of the command prompt each time I send it command to execute without closing the process after the execution of command. public void shell(String cmd) { ProcessStartInfo PSI = new ProcessStartInfo(); PSI.FileName = "c:\\windows\\system32\\cmd.exe"; PSI.RedirectStandardInput = true; PSI.RedirectStandardOutput = true; PSI.RedirectStandardError = true; PSI.UseShellExecute = false; Process p = Process.Start(PSI); StreamWriter CSW = p.StandardInput; StreamReader CSR = p.StandardOutput; CSW.WriteLine(cmd); CSW.Flush(); while(!(CSR.EndOfStream)) { Console.WriteLine(CSR.ReadLine()); } CSR.Close(); }

    Read the article

  • How to discriminate vertical from horizontal scroll on Kubuntu/KDE mouse action for switch Desktop

    - by sandroid
    Currently trying out KDE, and I'm a big user of multiple workspaces/desktops while I work. I've noticed that essentially, KDE isn't able (or doesn't bother?) to tell between my mouse's standard vertical scroll, and the left/right scroll that it has. Just FYI, my mouse has a pretty sensitive scroll wheel with no discernible "clicks" so I can easily make my desktop look like it's on crack. Here's what I'd like: vertical scroll does nothing when applied on desktop, but left/right scroll causes me to switch to previous/next desktop. Here's what happens now - per settings for Desktop Settings -- Mouse Actions: Whether I scroll up/down or if I click left/right, I switch desktops. Thanks for your help

    Read the article

  • Switch to https

    - by Mike
    I'm looking to use an .htaccess file to use mod_rewrite to switch the protocol from http:// to https:// when someone hits my website. For instance, once someone goes to: http://www.mywebsite.com/ I'd like the browser to switch to: http*s*://www.mywebsite.com/ The same goes for the http://mywebsite.com/ - https://mywebsite.com This is the following code I've been using and I've experienced some odd things so if anyone could provide me with information if this is the right way to do it, or if you have a better way, please provide it. Thanks in advance. RewriteEngine On RewriteCond %{SERVER_PORT} !=443 RewriteRule ^(.*)$ https://www.ebaillv.com/$1 [R=301,L]

    Read the article

  • Allow any arguments for a given command with sudo

    - by Mark L
    I have the following sudo config entry which I added via sudo visudo: mark ALL = NOPASSWD: /usr/bin/lxc-ls* I can run lxc-ls with my user fine but I can't append any parameters without it demanding I prefix the command with sudo. $ whoami mark $ lxc-ls test-container $ lxc-ls --fancy lxc-ls: error: You must be root to access advanced container properties. Try running: sudo /usr/bin/lxc-ls Any idea how I can edit via sudo visudo to allow for any argument after the command? I don't want to prefix the command with sudo as I'm using a python library to execute the command and it's being funny about sudo prefixes.

    Read the article

  • run gnom-terminal with excutable command

    - by user286251
    When i run gnome-terminal with the -e to execute a command the PATH used to find the command is not the PATH used in the terminal initiating the command For example: I open an terminal and set the PATH to be "./:$PATH type in gnome-terminal -e cluster_node It can't find the cluster node. if I type gnome-terminal -e ./cluster_node it works If I add in the /etc/environemtn the PATH ./ then it works always/ I think it doesn't use theterminal environment PATH from which it was launched.

    Read the article

  • Why can I not use a "constant" within a switch statement within scope?

    - by Clay Shannon
    With this code: public partial class Form1 : Form { private static readonly int TABCONTROL_BASICINFO = 0; private static readonly int TABCONTROL_CONFIDENTIALINFO = 1; private static readonly int TABCONTROL_ROLESANDSECURITY = 2; private static readonly int TABCONTROL_INACTIVEINFO = 3; . . . int ActiveTabPage = tabControlWorker.SelectedIndex; switch (ActiveTabPage) { case TABCONTROL_BASICINFO: if (currentNode == "NodeBuckingham") { } else if (currentNode == "NodeNamath") { } else if (currentNode == "NodeParsons") { } else { } break; ...I have to replace "TABCONTROL_BASICINFO" with "0", or I get, "A constant value is expected" Heavens to Murgatroyd! Can't it look up and see that TABCONTROL_BASICINFO is 0?

    Read the article

  • Why only the constant expression can be used as case expression in Switch statement?

    - by sinec
    Hi, what is bothering me is that I can't found an info regarding the question from the title. I found that assembly form the Switch-case statement is compiled into bunch of (MS VC 2008 compiler) cmp and je calls: 0041250C mov eax,dword ptr [i] 0041250F mov dword ptr [ebp-100h],eax 00412515 cmp dword ptr [ebp-100h],1 0041251C je wmain+52h (412532h) 0041251E cmp dword ptr [ebp-100h],2 00412525 je wmain+5Bh (41253Bh) 00412527 cmp dword ptr [ebp-100h],3 0041252E je wmain+64h (412544h) 00412530 jmp wmain+6Bh (41254Bh) where for above code will in case that if condition (i) is equal to 2, jump to address 41253Bh and do execution form there (at 41253Bh starts the code for 'case 2:' block) What I don't understand is why in case that,for instance, function is used as 'case expression', why first function couldn't be evaluated and then its result compared with the condition? Am I missing something? Thank you in advance

    Read the article

< Previous Page | 39 40 41 42 43 44 45 46 47 48 49 50  | Next Page >