Sign in to follow this  
Followers 0
WannaBeGut

Skype - Alert when somebody comes online!

5 posts in this topic

#1 ·  Posted (edited)

Hey,

I want the program to make different Actions when some persons come online, depending on the priority you choose in the GUI (1-3). It does not seem to work:

#include <Skype.au3>
#include <ButtonConstants.au3>
#include <EditConstants.au3>
#include <GUIConstantsEx.au3>
#include <StaticConstants.au3>
#include <WindowsConstants.au3>
#Region --- GUI START ---
$mainwin = GUICreate("Skype Notifier", 290, 186, 899, 341)
$label_user1 = GUICtrlCreateLabel("User1:", 16, 16, 63, 18)
GUICtrlSetFont(-1, 9, 400, 0, "Verdana")
$label_user2 = GUICtrlCreateLabel("User2:", 16, 48, 39, 18)
GUICtrlSetFont(-1, 9, 400, 0, "Verdana")
$label_user3 = GUICtrlCreateLabel("User3:", 16, 112, 36, 18)
GUICtrlSetFont(-1, 9, 400, 0, "Verdana")
$label_user4 = GUICtrlCreateLabel("User4:", 16, 80, 34, 18)
GUICtrlSetFont(-1, 9, 400, 0, "Verdana")
$label_user5 = GUICtrlCreateLabel("User5:", 160, 80, 49, 18)
GUICtrlSetFont(-1, 9, 400, 0, "Verdana")
$label_user6 = GUICtrlCreateLabel("User6:", 160, 48, 45, 18)
GUICtrlSetFont(-1, 9, 400, 0, "Verdana")
$label_user7 = GUICtrlCreateLabel("User7:", 160, 16, 32, 18)
GUICtrlSetFont(-1, 9, 400, 0, "Verdana")
$input_priority1 = GUICtrlCreateInput("0", 104, 16, 17, 21)
$input_priority2 = GUICtrlCreateInput("0", 104, 48, 17, 21)
$input_priority3 = GUICtrlCreateInput("0", 104, 80, 17, 21)
$input_priority4 = GUICtrlCreateInput("0", 104, 112, 17, 21)
$label_user8 = GUICtrlCreateLabel("User8:", 160, 112, 61, 18)
GUICtrlSetFont(-1, 9, 400, 0, "Verdana")
$input_priority5 = GUICtrlCreateInput("0", 240, 16, 17, 21)
$input_priority6 = GUICtrlCreateInput("0", 240, 48, 17, 21)
$input_priority7 = GUICtrlCreateInput("0", 240, 80, 17, 21)
$input_priority8 = GUICtrlCreateInput("0", 240, 112, 17, 21)
$button_arrowleft1 = GUICtrlCreateButton("<", 86, 16, 16, 22, $WS_GROUP)
$button_arrowright1 = GUICtrlCreateButton(">", 123, 16, 16, 22, $WS_GROUP)
$button_arrowleft2 = GUICtrlCreateButton("<", 86, 48, 16, 22, $WS_GROUP)
$button_arrowright2 = GUICtrlCreateButton(">", 123, 48, 16, 22, $WS_GROUP)
$button_arrowleft3 = GUICtrlCreateButton("<", 86, 80, 16, 22, $WS_GROUP)
$button_arrowright3 = GUICtrlCreateButton(">", 123, 80, 16, 22, $WS_GROUP)
$button_arrowleft4 = GUICtrlCreateButton("<", 86, 112, 16, 22, $WS_GROUP)
$button_arrowright4 = GUICtrlCreateButton(">", 123, 112, 16, 22, $WS_GROUP)
$button_arrowleft5 = GUICtrlCreateButton("<", 222, 16, 16, 22, $WS_GROUP)
$button_arrowright5 = GUICtrlCreateButton(">", 259, 16, 16, 22, $WS_GROUP)
$button_arrowleft6 = GUICtrlCreateButton("<", 222, 48, 16, 22, $WS_GROUP)
$button_arrowright6 = GUICtrlCreateButton(">", 259, 48, 16, 22, $WS_GROUP)
$button_arrowleft7 = GUICtrlCreateButton("<", 222, 80, 16, 22, $WS_GROUP)
$button_arrowright7 = GUICtrlCreateButton(">", 259, 80, 16, 22, $WS_GROUP)
$button_arrowleft8 = GUICtrlCreateButton("<", 222, 112, 16, 22, $WS_GROUP)
$button_arrowright8 = GUICtrlCreateButton(">", 259, 112, 16, 22, $WS_GROUP)
$button_apply = GUICtrlCreateButton("Apply", 176, 144, 103, 25, $WS_GROUP)
GUICtrlSetFont(-1, 8, 400, 0, "Verdana")
$checkbox_busy = GUICtrlCreateCheckbox("Busy Mode", 16, 144, 89, 25)
GUICtrlSetFont(-1, 8, 400, 0, "Verdana")
$checkbox_logfile = GUICtrlCreateCheckbox("Log File", 112, 144, 65, 25)
GUISetState(@SW_SHOW)
#EndRegion --- GUI END ---
Global $oSkype = ObjCreate("Skype4COM.Skype")
Global $oUser1 = $oSkype.User("User1")
Global $oUser2 = $oSkype.User("User2")
Global $oUser3 = $oSkype.User("User3")
Global $oUser4 = $oSkype.User("User4")
Global $oUser5 = $oSkype.User("User5")
Global $oUser6 = $oSkype.User("User6")
Global $oUser7 = $oSkype.User("User7")
Global $oUser8 = $oSkype.User("User8")
Global $SkypeStatus_Offline = $oSkype.Convert.TextToUserStatus("OFFLINE")
Global $SkypeStatus_Online = $oSkype.Convert.TextToUserStatus("ONLINE")
Global $SkypeStatus_Ringing = $oSkype.Convert.TextToCallStatus("RINGING")
Global $SkypeStatus_Inprogress = $oSkype.Convert.TextToCallStatus("INPROGRESS")
Global $SkypeStatus_Failed = $oSkype.Convert.TextToCallStatus("FAILED")
Global $SkypeStatus_Refused = $oSkype.Convert.TextToCallStatus("REFUSED")
Global $SkypeStatus_Cancelled = $oSkype.Convert.TextToCallStatus("CANCELLED")
Global $SkypeStatus_Finished = $oSkype.Convert.TextToCallStatus("FINISHED")
Global $SkypeStatus_Busy = $oSkype.Convert.TextToCallStatus("BUSY")
Global $SkypeStatus_Available = $oSkype.Convert.TextToAttachmentStatus("AVAILABLE")
Global $SkypeStatus_Invisible = $oSkype.Convert.TextToAttachmentStatus("AVAILABLE")
Global $mutestatus = $oSkype.Mute
Global $inputnumber1 = 0
Global $inputnumber2 = 0
Global $inputnumber3 = 0
Global $inputnumber4 = 0
Global $inputnumber5 = 0
Global $inputnumber6 = 0
Global $inputnumber7 = 0
Global $inputnumber8 = 0
Global $readpriority1 = GUICtrlRead($input_priority1)
Global $readpriority2 = GUICtrlRead($input_priority2)
Global $readpriority3 = GUICtrlRead($input_priority3)
Global $readpriority4 = GUICtrlRead($input_priority4)
Global $readpriority5 = GUICtrlRead($input_priority5)
Global $readpriority6 = GUICtrlRead($input_priority6)
Global $readpriority7 = GUICtrlRead($input_priority7)
Global $readpriority8 = GUICtrlRead($input_priority8)
Global $readcheckboxbusy = GUICtrlRead($checkbox_busy)
Global $readcheckboxlogfile = GUICtrlRead($checkbox_logfile)
Global $checkboxbusy = 0
Global $applystart = 0
Global $checkdone1 = 0

If Not $oSkype.Client.IsRunning Then
    $oSkype.Client.Start()
 EndIf
$oSkype.Attach(5)
If $SkypeStatus_Offline = $oSkype.CurrentUserStatus Then
    $oSkype.ChangeUserStatus($SkypeStatus_Online)
EndIf

 While 1
    $nMsg = GUIGetMsg()
        CheckingProcess()
    Switch $nMsg
        Case $GUI_EVENT_CLOSE
            Exit
        Case $button_apply
            Global $readpriority1 = GUICtrlRead($input_priority1)
            Global $readpriority2 = GUICtrlRead($input_priority2)
            Global $readpriority3 = GUICtrlRead($input_priority3)
            Global $readpriority4 = GUICtrlRead($input_priority4)
            Global $readpriority5 = GUICtrlRead($input_priority5)
            Global $readpriority6 = GUICtrlRead($input_priority6)
            Global $readpriority7 = GUICtrlRead($input_priority7)
            Global $readpriority8 = GUICtrlRead($input_priority8)
            Global $readcheckboxbusy = GUICtrlRead($checkbox_busy)
            Global $readcheckboxlogfile = GUICtrlRead($checkbox_logfile)
            Global $applystart = 1
         Case $button_arrowleft1
            $inputnumber1 = $inputnumber1 - 1
            If $inputnumber1 < 0 then $inputnumber1 = 0
            GUICtrlSetData($input_priority1, $inputnumber1)
         Case $button_arrowright1
            $inputnumber1 = $inputnumber1 + 1
            If $inputnumber1 > 3 then $inputnumber1 = 3
            GUICtrlSetData($input_priority1, $inputnumber1)
         Case $button_arrowleft2
            $inputnumber2 = $inputnumber2 - 1
            If $inputnumber2 < 0 then $inputnumber2 = 0
            GUICtrlSetData($input_priority2, $inputnumber2)
         Case $button_arrowright2
            $inputnumber2 = $inputnumber2 + 1
            If $inputnumber2 > 3 then $inputnumber2 = 3
            GUICtrlSetData($input_priority2, $inputnumber2)
         Case $button_arrowleft3
            $inputnumber3 = $inputnumber3 - 1
            If $inputnumber3 < 0 then $inputnumber3 = 0
            GUICtrlSetData($input_priority3, $inputnumber3)
         Case $button_arrowright3
            $inputnumber3 = $inputnumber3 + 1
            If $inputnumber3 > 3 then $inputnumber3 = 3
            GUICtrlSetData($input_priority3, $inputnumber3)
         Case $button_arrowleft4
            $inputnumber4 = $inputnumber4 - 1
            If $inputnumber4 < 0 then $inputnumber4 = 0
            GUICtrlSetData($input_priority4, $inputnumber4)
         Case $button_arrowright4
            $inputnumber4 = $inputnumber4 + 1
            If $inputnumber4 > 3 then $inputnumber4 = 3
            GUICtrlSetData($input_priority4, $inputnumber4)
         Case $button_arrowleft5
            $inputnumber5 = $inputnumber5 - 1
            If $inputnumber5 < 0 then $inputnumber5 = 0
            GUICtrlSetData($input_priority5, $inputnumber5)
         Case $button_arrowright5
            $inputnumber5 = $inputnumber5 + 1
            If $inputnumber5 > 3 then $inputnumber5 = 3
            GUICtrlSetData($input_priority5, $inputnumber5)
         Case $button_arrowleft6
            $inputnumber6 = $inputnumber6 - 1
            If $inputnumber6 < 0 then $inputnumber6 = 0
            GUICtrlSetData($input_priority6, $inputnumber6)
         Case $button_arrowright6
            $inputnumber6 = $inputnumber6 + 1
            If $inputnumber6 > 3 then $inputnumber6 = 3
            GUICtrlSetData($input_priority6, $inputnumber6)
         Case $button_arrowleft7
            $inputnumber7 = $inputnumber7 - 1
            If $inputnumber7 < 0 then $inputnumber7 = 0
            GUICtrlSetData($input_priority7, $inputnumber7)
         Case $button_arrowright7
            $inputnumber7 = $inputnumber7 + 1
            If $inputnumber7 > 3 then $inputnumber7 = 3
            GUICtrlSetData($input_priority7, $inputnumber7)
         Case $button_arrowleft8
            $inputnumber8 = $inputnumber8 - 1
            If $inputnumber8 < 0 then $inputnumber8 = 0
            GUICtrlSetData($input_priority8, $inputnumber8)
         Case $button_arrowright8
            $inputnumber8 = $inputnumber8 + 1
            If $inputnumber8 > 3 then $inputnumber8 = 3
            GUICtrlSetData($input_priority8, $inputnumber8)
    EndSwitch
 WEnd
 Func CheckingProcess()
            If $applystart = 0 then return
            Global $userstatus1 = $oSkype.Convert.OnlineStatusToText($oUser1.OnlineStatus)
            If $readpriority1 = 1 and $userstatus1 = "Online" or "Busy" then GUICtrlSetData($input_priority1, "!")
            If $readpriority1 = 2 and $userstatus1 = "Online" or "Busy" then  ChatAlert()
            If $readpriority1 = 3 and $checkboxbusy = 0 and $userstatus1 = "Online" or "Busy" then  MsgBox(0, "User Online!", "User1 ist Online!"&Chr(10))
            If $readpriority1 = 3 and $checkboxbusy = 1 and $userstatus1 = "Online" or "Busy" then  ChatAlert2()
            If $userstatus1 = "Do not Disturb" then $userstatus1 = "Busy"
            If $readcheckboxlogfile = 1 and $userstatus1 = "Online" or "Busy" then FileWrite("SkypeLog.txt", @MDAY&"/"&@MON&"/"&@YEAR&"/"&@HOUR&":"&@MIN&":"&@SEC&": "&"User1"&" is "&$userstatus1)

            Global $userstatus2 = $oSkype.Convert.OnlineStatusToText($oUser2.OnlineStatus)
            If $readpriority2 = 1 and $userstatus2 = "Online" or "Busy" then GUICtrlSetData($input_priority1, "!")
            If $readpriority2 = 2 and $userstatus2 = "Online" or "Busy" then ChatAlert()
            If $readpriority2 = 3 and $checkboxbusy = 0 and $userstatus2 = "Online" or "Busy" then MsgBox(0, "User Online!", "User2 ist Online!")
            If $readpriority2 = 3 and $checkboxbusy = 1 and $userstatus2 = "Online" or "Busy" then ChatAlert2()
            If $readcheckboxlogfile = 1 and $userstatus2 = "Online" or "Busy" then FileWrite("SkypeLog.txt", @MDAY&"/"&@MON&"/"&@YEAR&"/"&@HOUR&":"&@MIN&":"&@SEC&": "&"User2"&" is "&$userstatus2)
 EndFunc
 Func ChatAlert()
 EndFunc

 Func ChatAlert2()
 EndFunc

I hope you can help me! =)

Edit: I will make it a bit more neat when I get it to work ^^

Edited by WannaBeGut

Share this post


Link to post
Share on other sites



What does not seem to work? What is the issue you're seeing?


If I posted any code, assume that code was written using the latest release version unless stated otherwise. Also, if it doesn't work on XP I can't help with that because I don't have access to XP, and I'm not going to.
Give a programmer the correct code and he can do his work for a day. Teach a programmer to debug and he can do his work for a lifetime - by Chirag Gude
How to ask questions the smart way!

I hereby grant any person the right to use any code I post, that I am the original author of, on the autoitscript.com forums, unless I've specifically stated otherwise in the code or the thread post. If you do use my code all I ask, as a courtesy, is to make note of where you got it from.

Back up and restore Windows user files _Array.au3 - Modified array functions that include support for 2D arrays.  -  ColorChooser - An add-on for SciTE that pops up a color dialog so you can select and paste a color code into a script.  -  Customizable Splashscreen GUI w/Progress Bar - Create a custom "splash screen" GUI with a progress bar and custom label.  -  _FileGetProperty - Retrieve the properties of a file  -  SciTE Toolbar - A toolbar demo for use with the SciTE editor  -  GUIRegisterMsg demo - Demo script to show how to use the Windows messages to interact with controls and your GUI.  -   Latin Square password generator

Share this post


Link to post
Share on other sites

#3 ·  Posted (edited)

What does not seem to work? What is the issue you're seeing?

It will always think the Users are online, at least the MsgBox always pops up, the interesting thing is: If I display the $userstatus variable in a MsgBox, I can see it always shows the right state of the User (Online, Offline, Busy, Away)

If $readpriority2 = 1 and $userstatus2 = "Online" or "Busy" then GUICtrlSetData($input_priority1, "!")
Edited by WannaBeGut
Correction

Share this post


Link to post
Share on other sites

Try this change:

If $readpriority1 = 1 and ($userstatus1 = "Online" or $userstatus1 = "Busy") then GUICtrlSetData($input_priority1, "!")

 


If I posted any code, assume that code was written using the latest release version unless stated otherwise. Also, if it doesn't work on XP I can't help with that because I don't have access to XP, and I'm not going to.
Give a programmer the correct code and he can do his work for a day. Teach a programmer to debug and he can do his work for a lifetime - by Chirag Gude
How to ask questions the smart way!

I hereby grant any person the right to use any code I post, that I am the original author of, on the autoitscript.com forums, unless I've specifically stated otherwise in the code or the thread post. If you do use my code all I ask, as a courtesy, is to make note of where you got it from.

Back up and restore Windows user files _Array.au3 - Modified array functions that include support for 2D arrays.  -  ColorChooser - An add-on for SciTE that pops up a color dialog so you can select and paste a color code into a script.  -  Customizable Splashscreen GUI w/Progress Bar - Create a custom "splash screen" GUI with a progress bar and custom label.  -  _FileGetProperty - Retrieve the properties of a file  -  SciTE Toolbar - A toolbar demo for use with the SciTE editor  -  GUIRegisterMsg demo - Demo script to show how to use the Windows messages to interact with controls and your GUI.  -   Latin Square password generator

Share this post


Link to post
Share on other sites

#5 ·  Posted (edited)

Try this change:

If $readpriority1 = 1 and ($userstatus1 = "Online" or $userstatus1 = "Busy") then GUICtrlSetData($input_priority1, "!")

 

Just fixed it! That's what I did: (Thx anyways :D)

Local $userstatus1 = $oSkype.Convert.OnlineStatusToText($oUser1.OnlineStatus)
        If $userstatus1 = "Do Not Disturb" then $userstatus1 = "Busy"
        If $userstatus1 = "Online" then $uservalue1 = "Online"
        If $userstatus1 = "Offline" then $uservalue1 = "Offline"
        If $userstatus1 = "Busy" then $uservalue1 = "Online"
        If $userstatus1 = "Away" then $uservalue1 = "Offline"
        If $readpriority1 = 1 and $uservalue1 = "Online" then GUICtrlSetData($input_priority1, "!")
        If $readpriority1 = 2 and $uservalue1 = "Online" then Msg()
        If $readpriority1 = 3 and $busymode = 0 and $uservalue1 = "Online" then MsgBox(0, "User Online!", "User st Online!")
        If $readpriority1 = 3 and $busymode = 1 and $uservalue1 = "Online" then MsgImportant()

 

Edited by WannaBeGut

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0

  • Similar Content

    • pboom
      By pboom
      I am looking for a way to retrieve filtered messages from the ‘system debug channel.' also known as  ‘kernel-mode debug output.'

      AutoIt must do the capture in real time. The following AutoIt UDF almost does what is required but it only captures application level, or Win32 debug output.

      https://www.autoitscript.com/forum/topic/82889-capture-debug-information-udf/#comment-593268

      The utility DebugView by Sysinternals captures the information as required by turning on Capture Kernal and in my case using the Filter include:

      *Incoming connection*

      The use of DebugView to do this is covered in the following tech note;

      https://www.tacticalsoftware.com/support/tech-notes/logging-com-port-activity.htm

      https://technet.microsoft.com/en-us/sysinternals/debugview.aspx

      However to make to make the information from DebugView available to my AutoIt script required DebugView capture to a text file and then my AutoIt script monitor that file for changes. The use of DebugView to capture the system debug channel could be made to work, but it was less than reliable and difficult to get started. The startup wasn’t something that could be easily automated not even with AutoIt.

      If you understood what I am talking about and made it this far, I think an explanation of the application is in order. Lots of details here sorry trying to answer questions in advance.

      I support a large installation of General Electric MUSE application. MUSE is a Windows-based medical application that processes and archives ECGs (electrocardiograms) taken on dedicated hardware (ECG Carts). Several methods exist on the cart to get the ECG from the Carts to the MUSE system; they range from floppies (on old obsolete hardware), memory cards, RS232 serial ports, and hardwired network connections.

      In our installation, we choose not to use the vendor-supplied network solution due to a variety of reasons I won’t get into here.  Instead, we have designed our own connection solution.

      We use a wireless serial server mounted on the ECG carts connecting to a server running a Serial/IP COM Port Redirector. The ECG cart and MUSE application think they are talking to each other via an RS232 port and as far as they are concerned, they are. However, this RS232 cable happens to run through our province (think State) wide Health Care WAN.  The hardware and software used can be seen on these two sites;

      http://www.bb-elec.com/Products/Wireless-Cellular/AirborneM2M-802-11-a-b-g-n-Dual-Band-Wireless/AirborneM2M-Industrial-Dual-Band-Wi-Fi-Router-Brid.aspx

      https://www.tacticalsoftware.com/virtual-serial-port-redirector/serial-ip.htm

      This setup works well we have over 130 ECG carts connecting using this setup. However, the end users are not technical, and there is a lot that can go wrong with wireless connections. So we do get complaints, often after the fact, that the ECG cart would not connect. A log of what ECG carts connected and when would be very helpful.

      The Serial redirector software can be configured to log all activity to the Kernal-mode Debug output. The serial redirector software itself being kernel level software. For configuration of the Wireless modules, we have custom written software (written in AutoIt) that amongst other things can display relevant configuration information for a Wireless module given it’s IP address.

      By extracting messages like the ones below from the Kernal-Mode Debug channel;

      COM56 : ½ Incoming connection from 10.158.188.172:51562

      COM18 : ½ Incoming connection from 10.158.188.200:50896

      COM19 : ½ Incoming connection from 10.158.188.180:59074

      COM68 : ½ Incoming connection from 142.239.15.82:34322

      We can have the module configuration program retrieve the configuration. The retrieved configuration contains more information such as the module ID number and wireless signal strength. This information is then logged to a file which is later loaded into a database. We can then query the database for connections made by a particular module within a specified time frame. The results of these Queries help us determine if the module was connected or is having problems connecting. Problems are usually indicated by poor signal strength and frequent re-connecting.

      So what I am looking for is a way for our module configuration program (written in AutoIt) to retrieve filtered Kernal-Level debug messages directly without using the DebugView application.

      The Forum post listed at the first of this message includes the source code for the DLL. So if you are versed in these matters and Visual Studio this may be an easy task. I looked at what needed to be done but, I was way over my head. If you look up the price of the serial IP redirector software, you can see that there is some money in our project for such things however, I do have a spending limit for purchases such as this.

       
    • fosil
      By fosil
      Hi everyone.

      I'm currently working a program that constantly prints out log files through "consolewrite" and the "#AutoIt3Wrapper_Change2CUI=y" wrapper.

      Part of this program requires me to run a batch script.

      My issue is the batch script launches from the same window as consolewrite. I need the batch file to be launched through a different window as currently this causes an issue with the logs (which need to be very precise) but also causes the batch file to produce some funny behavior...

      Does anyone know how I can force the file to run on a second DOS window?

      Thanks in advance!!!
       
      Edit: Im using the "run" command if that helps. I tried "shellexecute" but that seemed to not launch the batch scripts at all.
    • nacerbaaziz
      By nacerbaaziz
      Hello guys
      I have an inquiry regarding bass.dll
      I wanted to record an audio file and did not know the way
      As well as I want to save the file after applying the effects
      can you help me?
      am sorry for my english
      With my greetings and best wishes
    • jollypk
      By jollypk
      hI,
      Is there any UDF for Zeromq ?
      I need to communicate with a remote and local socket. Any suggestion or guidance will be very appreciated.
       
      Thanks
    • FrancescoDiMuro
      By FrancescoDiMuro
      Good morning everyone
      I am working on a little script, which takes some data from a SQLite DB and should create a sort of report, inserting rows in a Word Document... I arrived at the point of:
      _Word_DocTableWrite() and, I don't know how to set the range parameter? What does that specify? 
      Thanks a lot for the help
      EDIT:
      Managed to write a table in the Word document, but now I get an error when I save the document with _Word_DocSaveAs(), with error 2.
      Which are possible causes? Thanks a lot, again
      EDIT 2:
      ... And, how can I set a border to the table? Maybe, with a sort of auto-formatting for text ( larger is the text, larger is the height/width of the table's cell ).
      Thanks  
      EDIT 3 ( bug ):
      Including the parameter $WdSaveChanges in the function _Word_DocSaveAs(), a save dialog box appears, and it should not do it, as it's written in the MSDN documentation:
      wdSaveChanges -1 Save pending changes automatically without prompting the user. Thanks again for everyone will answer to me