How can I keep my winform application running after logout

Dear developers,
I have an application that insert or update Data to an SQL server every 2, 3 hours.
I can’t use the SQL server itself (creating a new job). Instead I defined a timer which executes the code every 3 hours.
 The application runs in the server - a winform application.
And this is the problem, when I logoff the application is being closed…
Is there a way to keep the application running? (same as Jobs)
Tanks,
Patric

Uri's solution may work for you.
The proper approach though is a SQL Server Agent job. It resides on SS, it gives you nice history.
Talk with the responsible DBA?
Kalman Toth, SQL Server & Business Intelligence Training; SQL SERVER GRAND SLAM

Similar Messages

  • How can I debug a web application running on Weblogic 10.3

    Hello,
    I have inherited a NetUI Web Application developed using Weblogic Workshop and I can't manage to debug it. I have configure my server in Workshop and to debug it I right-click the project in Project Exporer and select Debug As -> Debug On Server, but this isn't working. The browser does open the application doesn't appear to be getting delpoyed.
    Can anyone help me out? I am using Weblogic 10.3 and Java 1.6.
    Thanks,
    Sean

    Hi Kal,
    The application is an enterprise application packaged as an EAR. if I right click on the project and click Debug As -> Debug on Server, the application appears in the Server Tab, but it does not start automatically. If I then manually start the server the application runs, but it does not stop at break points and I can not debug it.
    If I right-click on the web project that is packaged as part of the ear and select Debug As -> Debug On Server again the application is deployed, but I can't debug it. I don't get error messages, the application functions as normal but it does not stop at break points. When I attempt to debug the application via the Web Project, two browsers open automatically, both correctly displaying the application.
    Regards,
    Sean

  • Firefox does not load the first time I click on it -- a script appears which ischrome://webvideodownloader/content/utils.js:131 -- when I stop this script running I can then load firefox -- how can I keep this script from running

    I can still load it with the script running or attempting to run in the background but it makes firefox tremendously slow. After I click on stop running the script then everything seems to be ok.
    how do I get the script not to run in the first place.

    In Firefox the use of the term chrome refers to the user interface and other elements that are not part of the web pages.
    See https://developer.mozilla.org/en/Chrome
    Your problems seems to be caused by the GreaseMonkey extension.<br />
    See [[Troubleshooting extensions and themes]]

  • How can I config my jsp application run via port 80 or 443

    Hi All,
    I had jsp application, I deployed into Oracle Application Server 10g, when I test http://myhost.mydomain:7781/myapp then it is ok.
    Could you show me the way to config myapp run via default port 80 in Oracle As 10g. It is that if I input http://myhost.mydomain/ then it refrence to my jsp aplication.
    Thank All.
    Thanh.

    Thanh,
    check the $OracleAs_Midtier_Home/install/portlist.ini file for the ports that are configured for Oracle Application Server.
    If port 80 wasn't configured for the HTTP Listener then you will have to change the Application Server listener settings to make this work the way you want it.
    From the "Oracle Application Server 10g Administrator's Guide 10g (9.0.4) "
    Using the Application Server Control:
    Navigate to the Application Server home page and click Ports.
    On the Ports Page, locate the Oracle HTTP Server Listen port and click the icon in the Configure column.
    On the Server Properties Page, in the Listening Addresses and Ports section, enter the new port number in the Listening Port column. There may be more than one listening port listed. The only way to tell which is the non-SSL listening port is to choose the one with the old non-SSL listening port value.
    At the bottom of the page, click Apply.
    On the Confirmation Page, click No, you would not like to restart now.
    Using Manual Steps:
    Edit the following file:
    ORACLE_HOME/Apache/Apache/conf/httpd.conf
    Update the Listen directive with the new port number. Do not update the Port directive.
    There may be multiple Listen directives in this file. Modify the Listen directive that is not enclosed in an SSL virtual host container. The easiest way to locate the proper Listen directive is to search the file for the old listen port number.
    Save and close the file.
    Run the following command:
    dcmctl updateConfig -ct ohs
    Frank

  • How can I keep my macbook pro running 10.9.2 from continually freezing?

    My macbook pro running OSX 10.9.2 freezes randomly, sometimes before the computer has completely booted up.  I have no startup programs. Please help.

    Thank you for responding.
    EtreCheck results:
    Hardware Information:
              MacBook Pro (13-inch, Mid 2010)
              MacBook Pro - model: MacBookPro7,1
              1 2.66 GHz Intel Core 2 Duo CPU: 2 cores
              4 GB RAM
    Video Information:
              NVIDIA GeForce 320M - VRAM: 256 MB
    System Software:
              OS X 10.9.2 (13C1021) - Uptime: 0 days 0:4:31
    Disk Information:
              WDC WD10JPVX-22JC3T0 disk0 : (1 TB)
                        EFI (disk0s1) <not mounted>: 209.7 MB
                        Macintosh HD (disk0s2) / [Startup]: 999.35 GB (750.53 GB free)
                        Recovery HD (disk0s3) <not mounted>: 650 MB
              MATSHITADVD-R   UJ-898 
    USB Information:
              Apple Inc. Built-in iSight
              Apple Internal Memory Card Reader
              Apple Inc. BRCM2046 Hub
                        Apple Inc. Bluetooth USB Host Controller
              Apple Computer, Inc. IR Receiver
              Apple Inc. Apple Internal Keyboard / Trackpad
    Thunderbolt Information:
    Gatekeeper:
              Mac App Store and identified developers
    Kernel Extensions:
              [not loaded] com.avast.AvastFileShield (2.1.0 - SDK 10.9) Support
              [not loaded] com.avast.PacketForwarder (1.4 - SDK 10.9) Support
              [not loaded] com.pctools.iantivirus.kfs (1.0.1) Support
              [not loaded] com.smarttech.iokit.SMARTBoard (9.7) Support
              [not loaded] com.tectona.driver.PL2303 (1.3.0) Support
    Launch Daemons:
              [loaded] com.adobe.fpsaud.plist Support
              [loaded] com.tunnelbear.mac.tbeard.plist Support
    User Launch Agents:
              [loaded] com.adobe.ARM.[...].plist Support
              [loaded] com.avast.home.userinit.plist Support
              [failed] com.google.keystone.agent.plist Support
    User Login Items:
              None
    Internet Plug-ins:
              Flip4Mac WMV Plugin: Version: 3.2.0.16   - SDK 10.8 Support
              FlashPlayer-10.6: Version: 13.0.0.206 - SDK 10.6 Support
              Default Browser: Version: 537 - SDK 10.9
              Flash Player: Version: 13.0.0.206 - SDK 10.6 Support
              AdobePDFViewer: Version: 10.1.0 Support
              QuickTime Plugin: Version: 7.7.3
              OfficeLiveBrowserPlugin: Version: 12.3.6 Support
              Google Earth Web Plug-in: Version: 7.1 Support
              Silverlight: Version: 5.1.10411.0 - SDK 10.6 Support
              DirectorShockwave: Version: 12.0.9r149 - SDK 10.6 Support
              iPhotoPhotocast: Version: 7.0
    Safari Extensions:
              Translate: Version: 1.1
              Exposer: Version: 1.1
              avast! Online Security: Version: 8
              1-ClickWeather: Version: 1.0
              SafariRestore: Version: 6.0.1
    Audio Plug-ins:
              BluetoothAudioPlugIn: Version: 1.0 - SDK 10.9
              AirPlay: Version: 2.0 - SDK 10.9
              AppleAVBAudio: Version: 203.2 - SDK 10.9
              iSightAudio: Version: 7.7.3 - SDK 10.9
    iTunes Plug-ins:
              Quartz Composer Visualizer: Version: 1.4 - SDK 10.9
    3rd Party Preference Panes:
              Flash Player  Support
              Flip4Mac WMV  Support
              SMART Board  Support
    Time Machine:
              Auto backup: YES
              Volumes being backed up:
              Destinations:
                        Untitled 1 [Local] (Last used)
                        Total size: 0 B
                        Total number of backups: (null)
                        Size of backup disk: Excellent
                                  Backup size 0 B > (Disk size 0 B X 3)
              Time Machine details may not be accurate.
              All volumes being backed up may not be listed.
    Top Processes by CPU:
                   5%          kextd
                   3%          mds
                   2%          firmwaresyncd
                   1%          coreservicesd
                   1%          Finder
    Top Processes by Memory:
              106 MB          com.apple.WebKit.WebContent
              90 MB          Microsoft Word
              86 MB          Safari
              61 MB          WindowServer
              53 MB          Dock
    Virtual Memory Information:
              1.77 GB          Free RAM
              1.37 GB          Active RAM
              92 MB          Inactive RAM
              526 MB          Wired RAM
              272 MB          Page-ins
              0 B          Page-outs

  • Hello everyone. I have my itunes account for some years, and i've purchased far too many apps and music. Now the company i work for, has to change my account in the iphone, in order to use the corporate mails and calendar. How can i keep my applications?

    Hello everyone. I have my itunes account for some years, and i've purchased far too many apps and music. Now the company i work for, has to change my account in the iphone, in order to use the corporate mails and calendar. How can i keep my applications and music?

    Read here:
    http://support.apple.com/kb/ht5621
    Changing your Apple ID to your current, working email address will not create another Apple ID, it will only change it to your working email address.

  • How can I keep my signature on the left side when using rtl on mail application

    I'm writing in Hebrew & English on apple Mail application on OS X /mountain Lion.
    When I'm starting to write a mail in HEBREW it's automatically move the signature to the right side which I don't like it because my signature is in English (My Hebrew is a why better from my English ; )
    How can I keep the signature on the left side as default?
    Hope to get your support in this issue.
    Thanks in advance,
    Joni.

    Joni11 wrote:
    How could i do this?
    Sorry, I don't know.  But have you already tried selecting your sig and using the usual alignment tools?  It seems to work for me when used in the new message pane.

  • When using my new nano 7 with nike , my music stops after the 30 minute voice alert even though I have set my run for over 30 minutes.It cancels/deletes my run/workout when the music stops.This has happened several times.How can I keep this from happening

    When using my new nano 7 with nike+, my music stops after the 30 minute voice alert even though I have set my run/workout for over 30 minutes.  It also cancels/deletes that run/workout.  This has happened several times.  How can I keep this from happening?

    If possible I would arrange for a good service center to go over it. Hopefully they have a variety of parts in stock. They can test and verify all is working. The previous attempts are based on guesses by the person at the other end of the phone without diagnostic tests to assess the culprit. It is extremely unlikely for a webcam to fail & for it & a Mic to fail together should be an indicator to a good technician it is something else. EG Motherboard
    Take it to a servicing dealer and wait for it.
    T520 Model 4239 Intel(R) Core(TM) i7-2860QM CPU @ 2.50GHz
    Intel Sandy Bridge & Nvidia NVS 4200M graphics Intel N 6300 Wi-Fi adapter
    Windows 7 Home Prem - 64bit w/8GB DDR3

  • How can I detect if I'm running a compiled versione of my application?

    In my application I have included some special functions I don't want my customer to use. Since I will distribute the application as an .exe file, instead of cutting away those functions before releasing the .exe, I want to hide them when the application is runnig as an executable, and leave them active when running in the LV environment.
    How can I detect if I'm running an executable or the LV environment? Do I have to scan the application name until I find an .exe different from labview.exe or there is another way to obtain the flag (something similar to CVI function InStandaloneExecutable() for example)?
    Roberto
    Proud to use LW/CVI from 3.1 on.
    My contributions to the Developer Zone Community
    If I have helped you, why not giving me a kudos?

    An application property exists:Application:Kind
    with the following values: Development System, Runtime System, Student Edition, or Embedded LabVIEW.
    greetings from the Netherlands

  • Firefox 10 desktop shortcut reappears after deletion how can I keep it off desktop?

    I keep removing the desk top shortcut and within the day it reappears on its own. I use the quick launch bar at bottom of Windows 7 to launch firefox I don't need the extra shortcut. How can I keep the shortcut off my desktop?
    Windows 7 Home Premium 32-bit. AMD Athlon II x4 630 processor.
    Visionman Barebone PC

    Make sure that Firefox gets installed properly.
    Open the DMG file and drag to Firefox program to the application folder on your hard drive.
    You shouldn't double-click the Firefox application to run it from the disk image, but drag it out of the DMG folder instead.
    See:
    * [[Installing Firefox on Mac]]
    * http://kb.mozillazine.org/Installing_Firefox#Mac_OS_X

  • How can I keep my child from UNBLOCKING contacts or numbers I have blocked? I know in restrictions when you disable account changes at least on ios 6,this greyed out the iMessage button so the kids couldn't deactivate their text feature.

    Here's the issue.  Kids got themselves into some trouble on iPods.  We set all restrictions any turned off iMessage etc, which I noticed they can't turn back on bc it's gray with the don't allow account changes set.  BUT, it still allows Wi-Fi to be turned on and off!  How can I disable them being able to turn that on wo asking me??  In ios 7, the blocking feature, fabulous, BUT, how can I keep the kids from UNBLOCKING numbers I have blocked?  What I am looking to do actually is allow my kids to be able to text family but block everyone else.  And ask me to turn on wi fi.  How and can this even be done?  Right now my d text is turned off completely.  And she knows the inside and out of her device so she can turn wi fi on herself.  On vacation she entered the wi fi code of our condo and so I did forget network, which didn't work and wi fi kept connecting anyway wo requiring password again!  HELP!  Thanks :)  Also, they have iPods now but am asking these questions based on them getting our 4s's with ios 7.

    TeresaBoo, I empathize with your dilemma and have a similar problem. I'm trying desperately to keep my teenage daughter away from a controlling and abusive boyfriend. Of course, she is in denial and thinks it's love. Sure, I can block text messages through our wireless provider, but iMessages run on an independent network. I can block a phone number from iMessaging on her phone, but she can unblock it just as easily. I wish there was some way for parents to create a password to protect settings. Don't let negative comments get you down. Honestly, if someone can't relate to your question or offer help, why are they even bothering to comment??

  • I plan to loan my iPod Touch to a friend for one month to use in Europe.  How can I keep my iTunes account private, but enable him to create his own iTunes account to use on my iPod Touch?

    I plan to loan my iPod Touch to a friend here in the USA for one month to use on his trip to Europe.  How can I keep my iTunes content and my account private, but enable him to create his own iTunes account to use on my iPod Touch?  Also, do I need to de-register my iPod Touch for all of this to happen--and have him register my iPod Touch in his name for that month he is using it in Europe?

    very_nice wrote:
    The suggested advice in this support article http://support.apple.com/kb/HT1478 wasn't a help at all, because the option "enable disc use" in the summary window of itunes doesn't appear.
    *From the article*:
    Products Affected
    iTunes 7 for Mac, iTunes 7 for Windows, iPod nano, iPod shuffle, iPod mini, iPod, iTunes 8 for >Windows, iTunes 8 for Mac
    No mention of the Touch, it works differently from other iPods and has no "disk mode" as such.
    I think it can be used as a storage device by using a 3rd party App, search the the App Store for such items.
    Photos transferred to your Touch via iTunes will be of severely compromised quality i.e 640x480 pixel resolution and file size around 600-700 kb. These can be retrieved, again using a 3rd party application on your computer, such as [Touch Copy|http://www.wideanglesoftware.com/touchcopy> but you will not get back original quality images.
    Good luck,
    Dud.

  • How can I keep my MacBook safe is Apple is no longer supporting Snow Leopard? My MacBook was purchased in 2006 and cannot be upgraded to the newer operating systems.

    I have a MacBook which I purchased in 2006. It cannot upgrade to newer operating systems.Since Apple has stopped support to Snow Leopard, how can I keep my MacBook safe? Buying another computer is not an option. Any ideas or suggestions? Many thanks.

    Klaus1 wrote:
    Apple still sell, and therefore support, Snow Leopard.
    For what it's worth, from my reading of the Snow Leopard EULA (and I would  assume that there is similar language in the EULAs for all other operating systems, as well), I'm not seeing any obligation on the part of Apple to provide Security Updates of any kind, period/full stop. The wording appears to be completely "use at your own risk." I have no idea whether this "use at your own risk" would survive a legal challenge, or if such a legal challenge would depend on whether or not Apple is still selling (or even giving away for free) an OS, or whether local law would, according to this, override the EULA. Perhaps this is why Apple never formally announces EOL or discontinuance of support for an OS. They can always claim that they are still supporting an OS, whether or not in any practical sense, they are. There was even a very late Flashback detection and removal script which Apple issued for 10.5 well after it was clear that they had stopped supporting Leopard. This hardly constituted ongoing support, but perhaps it was to deter the threat of legal action, or maybe it was simply out of benevolence. I don't know.
    Besides that, even when Apple was still actively "supporting" Snow Leopard, which I don't think it is any longer, "use at your own risk" would still have applied to a case where Apple may have been late with a patch, or a response, or an adequate response, to a zero-day threat, such as Flashback was, which was constantly evolving. Many thousands were affected by that, and, to my knowledge, at least, there was no legal action directed at Apple throughout or after that episode. If there was any, I don't think it succeeded.
    7. Disclaimer of Warranties. YOU EXPRESSLY ACKNOWLEDGE AND AGREE THAT, TO THE EXTENT PERMITTED BY APPLICABLE LAW, USE OF THE APPLE SOFTWARE AND ANY SERVICES PERFORMED BY OR THROUGH THE APPLE SOFTWARE (COLLECTIVELY “SERVICES”) IS AT YOUR SOLE RISK AND THAT THE ENTIRE RISK AS TO SATISFACTORY QUALITY, PERFORMANCE, ACCURACY AND EFFORT IS WITH YOU. TO THE MAXIMUM EXTENT PERMITTED BY APPLICABLE LAW, THE APPLE SOFTWARE AND SERVICES ARE PROVIDED “AS IS” AND “AS AVAILABLE”, WITH ALL FAULTS AND WITHOUT WARRANTY OF ANY KIND, AND APPLE AND APPLE'S LICENSORS (COLLECTIVELY REFERRED TO AS “APPLE” FOR THE PURPOSES OF SECTIONS 7 and 8) HEREBY DISCLAIM ALL WARRANTIES AND CONDITIONS WITH RESPECT TO THE APPLE SOFTWARE AND SERVICES, EITHER EXPRESS, IMPLIED OR STATUTORY, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES AND/OR CONDITIONS OF MERCHANTABILITY, OF SATISFACTORY QUALITY, OF FITNESS FOR A PARTICULAR PURPOSE, OF ACCURACY, OF QUIET ENJOYMENT, AND NON-INFRINGEMENT OF THIRD PARTY RIGHTS. APPLE DOES NOT WARRANT AGAINST INTERFERENCE WITH YOUR ENJOYMENT OF THE APPLE SOFTWARE AND SERVICES, THAT THE FUNCTIONS CONTAINED IN, OR SERVICES PERFORMED OR PROVIDED BY, THE APPLE SOFTWARE WILL MEET YOUR REQUIREMENTS, THAT THE OPERATION OF THE APPLE SOFTWARE OR SERVICES WILL BE UNINTERRUPTED OR ERROR-FREE, THAT ANY SERVICES WILL CONTINUE TO BE MADE AVAILABLE, THAT THE APPLE SOFTWARE OR SERVICES WILL BE COMPATIBLE OR WORK WITH ANY THIRD PARTY SOFTWARE, APPLICATIONS OR THIRD PARTY SERVICES, OR THAT DEFECTS IN THE APPLE SOFTWARE OR SERVICES WILL BE CORRECTED. INSTALLATION OF THIS SOFTWARE MAY AFFECT THE USABILITY OF THIRD PARTY
    SOFTWARE, APPLICATIONS OR THIRD PARTY SERVICES. YOU FURTHER ACKNOWLEDGE THAT THE APPLE SOFTWARE AND SERVICES ARE NOT INTENDED OR SUITABLE FOR USE IN SITUATIONS OR ENVIRONMENTS WHERE THE FAILURE OR TIME DELAYS OF, OR ERRORS OR INACCURACIES IN THE CONTENT, DATA OR INFORMATION PROVIDED BY, THE APPLE SOFTWARE OR SERVICES COULD LEAD TO DEATH, PERSONAL INJURY, OR SEVERE PHYSICAL OR ENVIRONMENTAL DAMAGE, INCLUDING WITHOUT LIMITATION THE OPERATION OF NUCLEAR FACILITIES, AIRCRAFT NAVIGATION OR COMMUNICATION SYSTEMS, AIR TRAFFIC CONTROL, LIFE SUPPORT OR WEAPONS SYSTEMS. NO ORAL OR WRITTEN INFORMATION OR ADVICE GIVEN BY APPLE OR AN APPLE AUTHORIZED REPRESENTATIVE SHALL CREATE A WARRANTY. SHOULD THE APPLE SOFTWARE OR SERVICES PROVE DEFECTIVE, YOU ASSUME THE ENTIRE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. SOME JURISDICTIONS DO NOT ALLOW THE EXCLUSION OF IMPLIED WARRANTIES OR LIMITATIONS ON APPLICABLE STATUTORY RIGHTS OF A CONSUMER, SO THE ABOVE EXCLUSION AND LIMITATIONS MAY NOT APPLY TO YOU.
    8. Limitation of Liability. TO THE EXTENT NOT PROHIBITED BY APPLICABLE LAW, IN NO EVENT SHALL APPLE BE LIABLE FOR PERSONAL INJURY, OR ANY INCIDENTAL, SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES WHATSOEVER, INCLUDING, WITHOUT LIMITATION, DAMAGES FOR LOSS OF PROFITS, LOSS OF DATA, BUSINESS INTERRUPTION OR ANY OTHER COMMERCIAL DAMAGES OR LOSSES, ARISING OUT OF OR RELATED TO YOUR USE OR INABILITY TO USE THE APPLE SOFTWARE AND SERVICES OR ANY THIRD PARTY SOFTWARE OR APPLICATIONS IN CONJUNCTION WITH THE APPLE SOFTWARE, HOWEVER CAUSED, REGARDLESS OF THE THEORY OF LIABILITY (CONTRACT, TORT OR OTHERWISE) AND EVEN IF APPLE HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. SOME JURISDICTIONS DO NOT ALLOW THE LIMITATION OF LIABILITY FOR PERSONAL INJURY, OR OF INCIDENTAL OR CONSEQUENTIAL DAMAGES, SO THIS LIMITATION MAY NOT APPLY TO YOU. In no event shall Apple's total liability to you for all damages (other than as may be required by applicable law in cases involving personal injury) exceed the amount of fifty dollars ($50.00). The foregoing limitations will apply even if the above stated remedy fails of its essential purpose.
    http://images.apple.com/legal/sla/docs/osx_snow_leopard_sec_upd.pdf

  • Flash Builder 4.6 - How can I keep unit test classes out of the finished swc?

         I have a library of code I'm building and I'm working on unit testing but I have a major issue. When my finished swc compiles no matter what I do it includes the unit test classes as part of the intellisense if you load the swc via flash. The classes aren't really in the swc since if you just try and import them they'll come up undefined. They only appear to go into the intellisense for the swc. Does anyone know how can I keep this from happening in the finished source? Currently my folder setup is like this in flash builder.
    src\main - source documents for the library to get compiled
    src\mock - mock class area for unit testing
    src\test - unit test classes
         In the project Properties panel > the first tab of my Flex Library Build path I have selected only the src\main folder for the classes to inlude in the library. No other folder paths are selected.
    The "Flex Library Build Path" doesn't change my results with any setting.
    Thanks,

    Mel Riffe,
    Here's a Help topic about compiler options in Flash Builder: http://help.adobe.com/en_US/flashbuilder/using/WSe4e4b720da9dedb524b8220812e5611f28f-7fe7. html
    For information on using mxmlc, the application compiler, to compile SWF files from your ActionScript and MXML source files, you can see: http://help.adobe.com/en_US/flex/using/WS2db454920e96a9e51e63e3d11c0bf69084-7fcc.html
    Hope this helps,
    Mallika Yelandur
    Flash Builder Community Help & Learning
    Adobe Systems Incorporated

  • How can I communicate with other applications from my Java application?

    Hello,
    I need help about how can i communicate with other application(say textpad.exe/wordpad.exe/MS word.exe) from my Java program.
    More precisely, I need to know how i can get the current position of the cursor whether it is in any .txt/.doc files, then I may write some text in my java application and click a button and then my program will append the line(string) in that position of the file which is running under another appliction(Notepade.exe/MSword.exe).
    Please provide me some help.

    I may be wrong (and anyone, please correct me if so), but Java may not be the best tool for something such as this. I envision that you'd have to make some OS calls such as calls to the user32.dll, and while this can be done through the JNI, you'd still have to have a C or C++ program doing the dirty work.

Maybe you are looking for