Determine if service exists?

In Powershell, how do you determine if a windows service exists and stop it?
thanks

Hi Scott_m,
Mike's script should work, to start powershell Conditional Operators, please also check these articles:
Introduction to PowerShell Conditional Operators
Introduction to The Windows PowerShell If Statement
If you have any feedback on our support, please
click here.
Best Regards,
Anna
TechNet Community Support

Similar Messages

  • Item Category Determination for Service Agreement

    Hi,
    Which Item Category can be used for the Determination of Service Agreement.
    Thanks & Regards,

    Hi,
    Thanks for your response,
    Infact i had problem with the certain fields which were not displayed.
    Regards,

  • In DP50 Error during material determination for service order

    Hi,
    While doing Resources-Related Billing request,the following error is displaying..
    Kindly Help
    Error during material determination for service order
    Message no. AD01156
    Diagnosis
    An error occured during material determination for a dynamic item.
    System Response
    The system cannot perform the function.
    Procedure
    Check in the profile being used whether its characteristic allows the assignment of a material to each dynamic item.
    501384
    Message no. AD01156
    Diagnosis
    An error occured during material determination for a dynamic item.
    System Response
    The system cannot perform the function.
    Procedure
    Check in the profile being used whether its characteristic allows the assignment of a material to each dynamic item.
    Thanks,
    Mohit

    Hi mohit,
    You need to check DIP profile setting if profile is attached to your order type or not please check this
    Thanks and regards
    Sachin Kadam

  • Determining which services are associated with which programs

    In the Services Preferences, Services submenu, how does one determine which services are associated with which programs?

    Danged if I know! I just took a guess and enabled the ones I wanted, then tried what came up to see which program launched to do it. Some are easy: "Copy to Tex-Edit Plus" will obviously use the program Tex-Edit Plus. But I have no idea which program owns "New Document Containing Selection" and since I want TextEdit to handle that sort of thing I unchecked it, and simply checked "New TextEdit Window Containing Selection" because that's obviously TextEdit. I left "New Window with Selection" checked, and then tried it, and TextWrangler launched. OK, I do sometimes use it, so I left it checked. But it would be nice if it declared itself in the Service list so you could tell what program is going to do which thing. However, that is not Apple's fault--it is the fault of the application, someone just didn't bother to write a proper line for the system to display that would tell the user what application it is. That is probably because in the "old" Services menu items were arranged in folders by application, so there was no special need to have the service itself declare to whom it belonged. Perhaps this situation will change as applications are updated for Snow Leopard.
    I happen to know that the Services are declared to the system by the application, and the place this comes from is the Info.plist of the application, which is inside the application bundle. You can open this and check the plist: the service will be listed in the NSServices section in the NSMenuItem default field. Not something most people would ever want to do, you have to open the bundle then open the plist with Property List Editor.
    Meantime, I think trial and error is the only way to tell where the service is coming from. I would be delighted if someone knows otherwise.
    Francine
    Francine
    Schwieder

  • Service Category determination for Service Tax report

    Hi All,
    We have applied the SP18 at our client's place in which a new node of Service Tax has been introduced in IMG under Logistics. We would like to configure the Service Category under it.
    Suppose the access sequence is maintained as (any suitable) :
    Vendor + GL Acc + Tax code + Serv. Catg.
    GL Acc + Tax code + Serv. Catg.
    Vendor + Tax code + Serv. Catg.
    Tax code + Serv. Catg.
    We would like to know what is the significance of GL Acct. here. If anyone has used this configuration, kindly help us to understand.
    Also, suppose the existing service tax codes are Plant dependant then how do we map this scenario for determining Service Tax Category.
    Thanks & Regards,
    JND

    Hi Manfred,
    I don't know about "Ship-to arty" use in contract determination. AFAIK Sold2-Party, Sales and Service Organization, status of the Service Contract (released), Start and End date and the object list are responsible for the Contract determination. Hence if I'm not wrong a sold2-party must be provided.
    There is the CRM_SERVICE_CONTRACT Badi and what we did in our process is to use the Event framework to ensure a contract redetermination after change of the sold2-party. Take a look at CRM_SEARCH_SERV_CONTRACTS_EC for ideas in that direction.
    Regards,
    Hendrik

  • Org determination for Service & Sales Organization

    Gurus:
    Here is my objective and steps I have performed so far. Pl. guide me with your 'pearls of knowledge & experience'..!!
    Objective: To create Org determination profile so that when Campaign is released, prospective customer calls 1-800 number, based on the zipcode of the customer, an Appointment/Demonstration transaction is created and this transaction is routed to the Regional Sales/Service Office.
    Configuration done:
    1) Org structure with Regional Sales/Service is created. Do I have to create/assign 'zipcode' as attribute over here? If yes, do I just specify the Zipcode range for each office..? Do I select 'Object Permitted in determination'..?
    2) Do I have to create new Org Determination profile or I can use an existing one, such as '00000001 - Std Org data profile-Sale', which uses '10000280' as Org Det Procedure? I checked 10000280 (REG_SERV_04) and it uses zipcode as reference. I suppose we do not change/config anything with this rule correct..?
    Thanks in advance and full points for correct answer...
    Cheers,
    Niraj.

    Dear Niraj,
       I answer because I am interested in this topic. I will share what I know. When you set the flag "Object permitted for determination" the Organization is available for the transactions. So you must set this. Also, Zip code is maintained in the Attributes tab for the scenario that you choose. In your case, I think you choose Sales. This will help in the Orgnization data determination.
       This is as far as I know. Watching this space with interest.
    Regards,
    Sowmiya

  • No account determination for Service PR with acct assngmnt

    Dear Experts,
    I am creating a PR with account assignment as K (even any other like F, N) and Item category D. After completing the entery of all details like service number, qty and gross price, a new screen is appearing to enter the cost center but also the G/L account number.
    I have maintained the Valuation class in the service master and the automatic account determination settings in OBYC are aslo setup.
    I am surprised why it is not determining the G/L account?
    Can any one please guide me how to rectify this error?
    Edited by: b praveen savan on Aug 14, 2009 3:12 PM

    Hi Praveen,
    You have to enter the correct GL Account & Cost Center for each line items.
    You are going to procure the material with respect to GL Account, System doesn't know whether the accounting should go to which GL A/C & Cost Center.
    Here, The STD SAP Scenario is you are purchasing the material with respect to Location/Dept wise to restrict the Qty updation in stock.
    Regards,
    Mohd Ali.

  • Agent Determination for Service Entry (BO-BUS2091)

    HI,
    I am new to workflow and facing below issue.
    I have created a workflow for Service entry sheet approval (BO- BUS2901) and I am having an issue with the agent determination. I am using my own Ztable to determine the possible agents.
    I am using the following code in the FM of the rule I created for determining the agent:
    FUNCTION ZME_SRV_REL_GET_RESPONSIBLE.
    *"*"Local Interface:
    *"  TABLES
    *"      ACTOR_TAB STRUCTURE  SWHACTOR
    *"      AC_CONTAINER STRUCTURE  SWCONT
    *"  EXCEPTIONS
    *"      NOBODY_FOUND
    INCLUDE <cntain>.
    TABLES: essr_rel, essr,zmm_service_mail.
    DATA: object TYPE swc_object.
    DATA: BEGIN OF essrkey,
    lblni LIKE essr-lblni,
    END OF essrkey.
    DATA: verak_user TYPE csks-verak_user.
    REFRESH actor_tab.
    CLEAR actor_tab.
    swc_get_element ac_container 'service' object.
    if sy-subrc eq space.
    essrkey-lblni = object-objkey(10).
    select single * from essr where lblni = essrkey-lblni.
    select single * from zmm_service_mail
    where frggr = essr-frggr
    and frgsx = essr-frgsx.
    if essr-frgzu eq ' '.
    verak_user = zmm_service_mail-pernr1.
    elseif essr-frgzu eq 'x'.
    verak_user = zmm_service_mail-pernr2.
    endif.
    actor_tab-otype = 'us'.
    actor_tab-objid = verak_user.
    append actor_tab.
    endif.
    ENDFUNCTION.
    When I debug, sy-subrc = 8 at swc_get_element ac_container 'service' object.
    What could be the problem?
    Note- I have gone thru below thread but still I am unable to find the error.
    http://scn.sap.com/thread/2017416

    Hi,
    You should re-read the thread that you quoted above. The mighty Sue Keohan suggested a solution.
    Instead of trying to pass a service *object*, and then extracting the key, you can just pass the key itself.  It has type EESSR-LBLN1.
    swc_get_element ac_container 'service_key' lv_service_key.
    if sy-subrc eq 0.
      essrkey-lblni = lv_service_key.
    (etc)
    cheers
    Paul

  • Agent Determination for Service Entry

    Hi Guys,
    I created a workflow based on BO BUS2901 to send approval notification to an approver and I am having an issue with the agent determination. I am using the cost centre owner from the PR associated with the PO for the service entry as the approver.
    I am using the following code in the FM of the rule I created for determining the agent:
    FUNCTION ZME_REL_GET_RESPONSIBLE.
    *"*"Local Interface:
    *"  TABLES
    *"      ACTOR_TAB STRUCTURE  SWHACTOR
    *"      AC_CONTAINER STRUCTURE  SWCONT
    *"  EXCEPTIONS
    *"      NOBODY_FOUND
      INCLUDE <cntain>.
      TABLES: eban, essr_rel, essr, ekpo, ebkn, csks.
      DATA: object TYPE swc_object.
      DATA: BEGIN OF essrkey,
               lblni LIKE essr-lblni,
               ebeln LIKE essr-ebeln,
            END OF essrkey.
      DATA: verak_user TYPE csks-verak_user, kostl TYPE ebkn-kostl.
      REFRESH actor_tab.
      CLEAR actor_tab.
      swc_get_element ac_container 'ServiceEntry' object.
      IF sy-subrc EQ space.
        essrkey-lblni = object-objkey(10).
        essrkey-ebeln = object-objkey+10(10).
          select * from ekpo where ebeln = essrkey-ebeln.
            select single * from ebkn where banfn = ekpo-banfn.
              kostl = ebkn-kostl.
          endselect.
        select * from csks where kostl = kostl.
          verak_user = csks-verak_user.
        endselect.
        actor_tab-otype = 'US'.
        actor_tab-objid = verak_user.
        APPEND actor_tab.
      endif.
    ENDFUNCTION.
    When I debug, sy-subrc = 8 at swc_get_element ac_container 'ServiceEntry' object.
    What could be the problem?
    Thanks
    Regards

    Hi Sarvesh, T
    This thread was already answered some time ago.  Please open a new Discussion marked as a question.  If the thread you originally posted to has material related to your question, include a link.  Your content is attached below to make it easy for you to simply paste it into the new Discussion.  It is recommended to read the Rules of Engagement and other documents in the Getting Started link at the top right.   If you have any questions, feel free to respond to this DM (Direct Message) and I will be happy to try to assist.
    Rgds,
    Jocelyn (SCN moderator)

  • Contract determination in service order for PPR items

    Hi Experts,
    Contract data is not being determined for some items in service order. All these items are assigned to product list in service contract using product range or PPR.
    1) PPR is created with the type "sales contract"
    2) In the categories section assigned the relevant category ID's
    3) PPR is assigned to the service contract under product list.
    4) Service order is maintained for contract determination 'D'  - determination both at header and item level
    5) When a service order is created I see that expected items are not showing the contract data.
    Any suggestions - any specific setting I am missing
    I found a SAP note for same problem in previous versions of CRM. (5.0 to 5.1)
    but we are on BBPCRM 6.0
    Thank you
    Ram

    Hi Shalini
                    i am trying to create a service ticket from WEB IC by confirming Account and Ibase and then creating service request and able to save without error. 
                if i end session and open the service request again in change mode and if delete the ibase, then appeas the message
    "You should run a new contract selection for item 0000000010",  going through OSS notes, but found nothing.
               Contract Determination is set to 'E' : Assign at Item leve : Assign immediately if unique for transaction type ZXXX.
    if i open the service ticket in CRMD_ORDER and go in change mode if i click process action button next to error, this will disappear. but it comes when i assing a ibase to the request, so its working only when i create.
    any sort of help will be appreciated.
    Thanks
    Gopi

  • How to Determine Whether Columns Exist in a Table

    Greetings,
    Because of customizations to our product, certain database table structures vary between different client installations. Hence, in the code, I need to determine whether two columns exist in a certain table, in order to apply some business logic.
    Please suggest a way for me to determine whether two named columns appear in a specific table. In other words, for example, I need to discover whether both columns SAL_GRADE and BONUS appear in the EMP table, or not. Only if both columns are defined, can I apply my business logic.
    Thanks,
    Avi.

    Avi,
    Like this ?
    SQL> declare
      2    l_count number;
      3  begin
      4    select count(*)
      5      into l_count
      6      from user_tab_columns
      7     where table_name = 'EMP'
      8       and column_name in ('SALGRADE','BONUS')
      9    ;
    10    if l_count = 2
    11    then
    12      dbms_output.put_line('Both columns exist, so apply business logic');
    13    else
    14      dbms_output.put_line('One or both columns are missing, so don''t apply business logic');
    15    end if;
    16  end;
    17  /
    One or both columns are missing, so don't apply business logic
    PL/SQL-procedure is geslaagd.Regards,
    Rob.

  • Posting Keys for Account Determination do not exist

    This doubt in STO scenario:
    STO - between 2 plants - different company codes under same client
    Created STO from  Receiving Plant in ME21N with document type NB
    Based on that STO, Created Delivery in VL10B from supplying Plant
    Tried PGI in VL02N from supplying Plant.
    Received the Error Message as below:
    Posting keys for account determination for transaction BUV do not exist
    Message no. F5598
    Diagnosis
    The posting keys necessary for account determination for transaction BUV have not been set.
    System Response
    Because the posting key is missing, the system cannot generate any automatic postings.
    Procedure
    Maintain the posting keys necessary for transaction BUV.
    kindly give the solution and advance thanks.
    Vaidee

    Hi Vadee,
    Account Determination for BUV has not been setup for PGI.
    So , go to transaction OBYC and assign the account by double clicking BUV  and give u r chart of accounts and check whether the account has been maintained. If not maintain.
    If account has been maintained , select your account/valuation class and select posting keys push button and maintain the posting keys.
    Regards,
    Nani

  • Automatic tax code determination for service POs

    Hi
    Can anyone tell  about the possibilities of automatic tax code determination for the service purchase orders.
    Thanks in advance
    Durai

    The tax indicator is used in the automatic determination of the tax code 
    in Purchasing.                                                                               
    The tax code can be determined automatically within the framework of tax 
    determination (via the conditions).                                      
    Tax indicators, which can come from the service master record,           
    Customizing, or the purchasing document, are used in this process. The   
    system determines the tax code on the basis of the combination of these  
    tax indicators.                                                                               
    Automatic determination of the tax code is useful, for example, if       
    different tax rates apply to different groups of services.

  • Automatic Tax Determination for Services

    Hi MM consultants....
    Today I hav this question...
    In Service Master (AC03) I have a Tax Indicator, but when I generate a PO for this Service, the tax is not determined automatically...
    How can I move the Tax Indicator in Service Master to the Purchase Order automatically??
    It works for materials, but not for services...
    What can I do?
    Regards...

    Hi,
    You need to activate taxes at the service level in configuration. Menu path is MM / External service management / Taxes at individual service level.
    Regards

  • Auto determination of Service Organization and Org.Unit

    Hello
    I've created an Org.Model with Org.Units. I've also configured a rule to derive the service organization and the responsible Org Unit based on the activity reason.
    When i manually specify the activity reason in the transaction, both service org and org. unit are not automatically derived. As a result I have to manually specify them.
    What am I missing here?
    Your help is greatly appreciated

    header level
    spro-> crm->MD.,->org mang.,->org data determination->change rules and profiles ->assign org data profile to transaction type .
    add ur profile under org data prifle for ur transaction profile .
    item level
    spro-> crm->MD.,->org mang.,->org data determination->change rules and profiles ->assign org data profile to item  .

Maybe you are looking for

  • While scheduling I am getting the Exception [TOPLINK-4002] Error

    Dear All, While scheduling I am getting the following Error Exception [TOPLINK-4002] (Oracle TopLink - 10g Release 3 (10.1.3.0.0) (Build 060118)): oracle.toplink.exceptions.DatabaseException Internal Exception: java.sql.SQLException: No more data to

  • Joins and where execution

    When two tables are joined and there is a where predicate, what is done first ? 1) the WHERE in order to filter the records being joined. 2) the JOIN and after both tables are together with all their records Oracle filters according to the where pred

  • Proforma Invoice-cancel

    Dear Friends, Is there any way to cancel proforma invoice....suppose if the user has done some mistake in Proforma invoice, will it be possible to cancel it...? pls throw some light on this...would be helpful... points assured Krishna chaitanya

  • OCS Reverse Proxy via Apache 2.0

    I'm trying to configure an OCS 10.1.2 (OCS 10g R2) one-box install behind an Apache2 reverse proxy. Has anyone been able to do this? I've configured a virtual host with ProxyPass and ProxyPassReverse directives, however, I'm not sure which component

  • Workflow gets hanged

    Hi All, I have a problem in workflow where it gets hanged at some cases . It gets hanged in a user decision step. When i checked the log, comparing with the correctly executed workflow, i found in the step history tab the executed action - Result pro