FireFox Posted February 28, 2013 Author Share Posted February 28, 2013 Uh. Now I think I got it! Works perfectly now. Thanks a lot for your UDF, help and such a quick bugfix! You're welcome Link to comment Share on other sites More sharing options...
Mouette Posted March 23, 2013 Share Posted March 23, 2013 Nothing else to say ..... except maybe .... What a great job man Congrat! FireFox 1 Link to comment Share on other sites More sharing options...
hiho Posted April 3, 2013 Share Posted April 3, 2013 Hi, i'm trying to read the latest message from a given username, but whatever I do, I can't get it done. Can you give me an example or show me what am I doing wrong? #include <Skype.au3> #include <Array.au3> $test =_Skype_ChatCreateWith("username") Global $a = _Skype_ChatMessageGetBody($test) _ArrayDisplay($a) Link to comment Share on other sites More sharing options...
FireFox Posted April 3, 2013 Author Share Posted April 3, 2013 Hi, Here you go : #include "Skype.au3" Local Const $aChat = _Skype_ChatGetAll() Local $oChat = 0, $aMember = 0, $sChatName = "" For $iChat = 0 To UBound($aChat) -1 $oChat = $aChat[$iChat] #region 1 $aMember = _Skype_ChatGetMembers($oChat) If IsArray($aMember) = 0 Then ContinueLoop For $iMember = 1 To $aMember[0] -1 ConsoleWrite($aMember[$iMember] & ", ") Next ConsoleWrite(@CrLf) #endregion $sChatName = _Skype_ChatGetName($oChat) ConsoleWrite($sChatName & @CrLf & @CrLf) If $sChatName = "#abc.def/$whatever" Then ExitLoop Next Local $sMsgBody = "" For $oMsg In $oChat.Messages $sMsgBody = _Skype_ChatMessageGetBody($oMsg) If $sMsgBody = "" Then ContinueLoop ConsoleWrite("Last message (" & _Skype_ChatMessageGetDate($oMsg) & "): " & $sMsgBody & @CrLf) ExitLoop Next You need to find the chat name thanks to the console, then you can comment everything which is in the region 1. Br, FireFox. Link to comment Share on other sites More sharing options...
hiho Posted April 3, 2013 Share Posted April 3, 2013 (edited) Hi FireFox, again, after runing the above code, I get an error about the array(s) : !>Error Number: 0 Description: 0 C:\Program Files\AutoIt3\Include\Skype.au3 (3377) : ==> Array variable subscript badly formatted.: Local $aChats[$iChats], $i Local $aChats[^ ERROR I get the similar error but with other code ( i'll try to reproduce it if you like ): C:Program FilesAutoIt3IncludeSkype.au3 (2386) : ==> Array variable subscript badly formatted.: Local $aChatMessages[$iChats][4], $i Edited April 3, 2013 by hiho Link to comment Share on other sites More sharing options...
FireFox Posted April 3, 2013 Author Share Posted April 3, 2013 Hm... Try the #RequireAdmin function and if it does not work : #include "Skype.au3" $oSkype.Attach() While 1 Sleep(10) If _Skype_GetAttachmentStatus() = $cAttachSuccess Then ExitLoop WEnd ;your code here. Br, FireFox. Link to comment Share on other sites More sharing options...
hiho Posted April 3, 2013 Share Posted April 3, 2013 !>Error Number: 0 Description: 0 and... nothing happens. Link to comment Share on other sites More sharing options...
FireFox Posted April 3, 2013 Author Share Posted April 3, 2013 Replace the Skype_Error function with this one (don't forget to rename it) : Func MyErrFunc($oError) MsgBox(0, "", "err.number is: " & @TAB & $oError.number & @CRLF & _ "err.windescription:" & @TAB & $oError.windescription & @CRLF & _ "err.description is: " & @TAB & $oError.description & @CRLF & _ "err.source is: " & @TAB & $oError.source & @CRLF & _ "err.helpfile is: " & @TAB & $oError.helpfile & @CRLF & _ "err.helpcontext is: " & @TAB & $oError.helpcontext & @CRLF & _ "err.lastdllerror is: " & @TAB & $oError.lastdllerror & @CRLF & _ "err.scriptline is: " & @TAB & $oError.scriptline & @CRLF & _ "err.retcode is: " & @TAB & $oError.retcode) EndFunc ;==>_ErrFunc Link to comment Share on other sites More sharing options...
hiho Posted April 3, 2013 Share Posted April 3, 2013 I feel like an idiot I forgot that I blocked "AutoIT.exe" from my personal skype while making the other script. Everything works fine, sorry for troubling you, Link to comment Share on other sites More sharing options...
FireFox Posted April 3, 2013 Author Share Posted April 3, 2013 I feel like an idiot I forgot that I blocked "AutoIT.exe" from my personal skype while making the other script. Everything works fine, sorry for troubling you,No problem @everyoneNew version available ! (see first post for update)Br, FireFox. Link to comment Share on other sites More sharing options...
victor141516 Posted April 12, 2013 Share Posted April 12, 2013 I have discovered this today and the first thing I tried have been to send a message in the current chat, so this is the code: #include "Skype.au3" _Skype_ChatSendMessage(_Skype_ChatGetActive(),"hola") I think it should work, but I get an error: err.number is: 169 err.windescription: Variable must be of type 'Object'. err.description is: err.source is: err.helpfile is: err.helpcontext is: 0 err.lastdllerror is: 0 err.scriptline is: 2650 Link to comment Share on other sites More sharing options...
FireFox Posted April 12, 2013 Author Share Posted April 12, 2013 Hi, The _Skype_ChatGetActive function returns an array containing all active chats and not an object. Take a look at the replies from this topic and you will find what you need Br, FireFox. Link to comment Share on other sites More sharing options...
victor141516 Posted April 13, 2013 Share Posted April 13, 2013 Hi, The _Skype_ChatGetActive function returns an array containing all active chats and not an object. Take a look at the replies from this topic and you will find what you need Br, FireFox. Oh fine, but then I think this could be wrong: ; #FUNCTION# ==================================================================================================================== ; Name...........: _Skype_ChatGetActive ; Description ...: Queries active chat object ; Syntax.........: _Skype_ChatGetActive() ; Parameters ....: None ; Return values .: Success - Active chat object ; Failure - 0 [Sets an error event] ; Author ........: FireFox (d3mon) ; Modified.......: ; Remarks .......: ; Related .......: ; Link ..........: ; Example .......: Yes ; =============================================================================================================================== I mean this: ; Return values .: Success - Active chat object Link to comment Share on other sites More sharing options...
FireFox Posted April 13, 2013 Author Share Posted April 13, 2013 (edited) Yes, you're right. I changed the function name to _Skype_ChatGetAllActive $aActiveChat = _Skype_ChatGetAllActive() $aActiveChat[0] ;current opened chat @everyone New version available ! (see first post for update) Br, FireFox. Edited April 13, 2013 by FireFox Link to comment Share on other sites More sharing options...
lionfaggot Posted April 24, 2013 Share Posted April 24, 2013 so, off topic, i have a question but before i begin. there was no function that i could find within skype4com to check if a user exists on skype. so i made one that uses the jquery on skypes signup page. heres the function i made: Func _checkskypeuser($skuser) $skhtml = BinaryToString(InetRead("https://login.skype.com/json/validator.php?new_username="&$skuser,1)) If StringInStr($skhtml, "Skype Name not available") Then Return 1 EndIf EndFunc as for my question, how do i get the user handle of someone who is attempting to send me a friend request? Link to comment Share on other sites More sharing options...
EmptySpace Posted May 18, 2013 Share Posted May 18, 2013 Its possible to do this portable? I mean I run real skype on my pc, and I want to run other skype profile with this UDF. Link to comment Share on other sites More sharing options...
FireFox Posted May 18, 2013 Author Share Posted May 18, 2013 Hi,I don't understand what you mean.Do you want to run more than one instance on your computer?OR you have a portable skype and you ask if it's possible to use this UDF?Br, FireFox. Link to comment Share on other sites More sharing options...
EmptySpace Posted May 18, 2013 Share Posted May 18, 2013 (edited) Sorry for my bad english. Â I want to run more than one instance on my computer. I need to run few skype accounts at the same time. Edited May 18, 2013 by SherminatoR Link to comment Share on other sites More sharing options...
FireFox Posted May 18, 2013 Author Share Posted May 18, 2013 You need to run the Skype with this parameter " /secondary"I don't know if you can target a skype instance with the Skype4COM library, I will make some searches tonight. Meanwhile if you find something you can post it Br, FireFox. Link to comment Share on other sites More sharing options...
hiho Posted May 18, 2013 Share Posted May 18, 2013 Hi, if I understand you correct, you're asking if it's possible to have 2 Skype accounts running at the same time and one of them being manupulated with the UDF? If this is what you want to accomplish, then simply deny the access of the complied script when it asks for permission to use Skype. Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now