AndreyS Posted October 27, 2017 Posted October 27, 2017 Developers, can anyone explain this phenomenon to me? Run this code and wait for nothing without doing a few minutes and you will start receiving randomly, either one or the second message. But none of them should never appear on the logic of the code! As I understand sometimes the function ClipGet () returns an empty value. Why is this happening? Dim $ClipGetText ClipPut("12345") While 1 Sleep(5) ;reduced to 5 to better see the problem if ClipGet()<>$ClipGetText And ClipGet()<>"" Then $ClipGetText=ClipGet() Beep(800,100) ConsoleWrite(ClipGet()&"|"&$ClipGetText&@CRLF) ElseIf ClipGet()="" Then Beep(800,100) ConsoleWrite("Empty"&@CRLF) EndIf WEnd
Moderators JLogan3o13 Posted October 27, 2017 Moderators Posted October 27, 2017 I let it run for 10 minutes and saw nothing beyond the initial Quote 12345|12345 "Profanity is the last vestige of the feeble mind. For the man who cannot express himself forcibly through intellect must do so through shock and awe" - Spencer W. Kimball How to get your question answered on this forum!
Moderators Melba23 Posted October 27, 2017 Moderators Posted October 27, 2017 AndreyS, Same result here. M23 Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind Open spoiler to see my UDFs: Spoiler ArrayMultiColSort ---- Sort arrays on multiple columnsChooseFileFolder ---- Single and multiple selections from specified path treeview listingDate_Time_Convert -- Easily convert date/time formats, including the language usedExtMsgBox --------- A highly customisable replacement for MsgBoxGUIExtender -------- Extend and retract multiple sections within a GUIGUIFrame ---------- Subdivide GUIs into many adjustable framesGUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView itemsGUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeViewMarquee ----------- Scrolling tickertape GUIsNoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxesNotify ------------- Small notifications on the edge of the displayScrollbars ----------Automatically sized scrollbars with a single commandStringSize ---------- Automatically size controls to fit textToast -------------- Small GUIs which pop out of the notification area
AndreyS Posted October 27, 2017 Author Posted October 27, 2017 (edited) Then I do not know how to explain this ?! I see over 3 minutes, for example the following: Empty Empty Empty 12345 | 12345 Empty Empty Edited October 27, 2017 by AndreyS
BrewManNH Posted October 27, 2017 Posted October 27, 2017 I am still running it and it's been 25 minutes and the only time it shows empty is occasionally when I copy something new to the clipboard. Other than that it's being completely quiet. 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 GudeHow 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
AndreyS Posted October 27, 2017 Author Posted October 27, 2017 Here again I launched and for one minute received the following result: 12345 | 12345 12345 | 12345 12345 | 12345 12345 | 12345 12345 | 12345 12345 | 12345 12345 | 12345 Empty 12345 | 12345
BrewManNH Posted October 27, 2017 Posted October 27, 2017 Why does your output keep showing the 12345|12345? 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 GudeHow 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
AndreyS Posted October 27, 2017 Author Posted October 27, 2017 No no - you do not need to copy anything while doing this. "only time it shows empty" And yet you have received this message at least once! And it should not have been one! I do not know why the rest do not get such problems. Maybe it depends on the power of the computer.
AndreyS Posted October 27, 2017 Author Posted October 27, 2017 "Why does your output keep showing the 12345 | 12345?" As I understood and wrote above, the ClipGеt() function seems to fail to work and produces an empty result because of this and this problem is obtained.
BrewManNH Posted October 27, 2017 Posted October 27, 2017 Your script as written above should never produce this output. Quote 12345 | 12345 12345 | 12345 12345 | 12345 12345 | 12345 12345 | 12345 12345 | 12345 12345 | 12345 Empty 12345 | 12345 As to my results showing empty, as I stated, it only shows the empty line when I copy new information to the clipboard. 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 GudeHow 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
AndreyS Posted October 27, 2017 Author Posted October 27, 2017 (edited) I still thought that! Maybe some third-party program affects the clipboard somehow ?! I'll try to close all programs as much as possible and see if there is any dependence! Yes, yes, based on the code, there should not be a single message other than the first. Edited October 27, 2017 by AndreyS
AndreyS Posted October 27, 2017 Author Posted October 27, 2017 I seem to have caught the dependence on one of my programs. In it there is such line: If ClipGet() <> $TextForClipb And StringInStr(ClipGet(), ":") > 0 And Number(StringMid(ClipGet(), StringInStr(ClipGet(), ":") + 1, 1)) > 0 And StringLen(ClipGet()) < 40 Then ... Tell me, can it affect the contents of the clipboard? And because of this, I get that output messages that should not be displayed?
AndreyS Posted October 27, 2017 Author Posted October 27, 2017 I found respected developers dependency! It turns out you can not even just access simultaneously from different scripts to the buffer! Otherwise, such inadequate results are obtained. Copy the following script: Dim $CBValue While 1 $CBValue=ClipGet() WEnd Run it and then run my example.
Moderators JLogan3o13 Posted October 27, 2017 Moderators Posted October 27, 2017 Is this what you've been doing? Why didn't you explain this in the beginning? The last two posts are completely different than your first; we can't help you when you're not giving us all the info up front. "Profanity is the last vestige of the feeble mind. For the man who cannot express himself forcibly through intellect must do so through shock and awe" - Spencer W. Kimball How to get your question answered on this forum!
AndreyS Posted October 27, 2017 Author Posted October 27, 2017 (edited) JLogan3o13 you do not correctly understand me apparently. You need to run two scripts! Compile the last and run. And from the editor, run my first code! The second script I just invented quickly to check how they will work in parallel. Also I understood why you do not receive messages, and I received. My second program, which was always running when developing a new program, also uses ClipGet (). So there was a conflict. What is the problem and how to solve it now? After all, any scripts should work correctly and do not have such influence on each other. Edited October 27, 2017 by AndreyS
AndreyS Posted October 28, 2017 Author Posted October 28, 2017 Dear experts, I'm very grateful to you for responding so quickly to my topic! But where did you all disappear so quickly? You do not understand the problem or think how to solve it? Say at least something please.
Developers Jos Posted October 28, 2017 Developers Posted October 28, 2017 My guess is that this whole topic till now isn't make much sense so hence am I staying out. I see absolutely no reason why one would want to do what you are trying to test here. Tell us exact information on how you fill/refresh the clipboard and what it is you want to do that isn't working and you might have better luck getting answers. Jos SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past.
AndreyS Posted October 28, 2017 Author Posted October 28, 2017 So you really do not understand anything? I've given you two scripts that show that the ClipGet () function is buggy when it uses two different scripts at the same time! This is absurd and so it should not be! You still do not understand anything?
Developers Jos Posted October 28, 2017 Developers Posted October 28, 2017 Just now, AndreyS said: This is absurd and so it should not be! You still do not understand anything? mmm.... Is this your polite way of asking for help, not answering any of my questions and arguing that I am stupid? Fuck you too! Jos SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past.
AndreyS Posted October 28, 2017 Author Posted October 28, 2017 So when one of the programs uses the ClipGet () function, then that gets absurd results when using ClipGet () at this time. That's what I showed you on the example of my two scripts. I showed you this in examples and in different ways and tried to answer all your questions! If on some did not answer then I did not understand them! I'm not special, like you, in English! Jos, I did not insult you in the least way since you insulted me now! I'm talking only about the error in language and function. And you insulted me! Thank you for such help: send me away. From whom from whom but from you I did not expect this and had a different opinion.
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