Jump to content

TheDcoder

Active Members
  • Posts

    7,103
  • Joined

  • Days Won

    88

Everything posted by TheDcoder

  1. @Arlen I am not sure that I understand, this UDF does not run the script itself again, but it rather uses a hack to have the callback function (the function which is supplied to the _AuThread_StartThread function) run asynchronously along side the main script... expect a lot of errors though.
  2. @mLipok Oops, did not notice that you were already attempting to do it. I just read the feature request in SciTE's source forge page and wanted to give you my suggestion. I am not sure if SendMessage is the appropriate function to call since SCI_SETREADONLY is a function and not a message , the documentation does list a message called EM_SETREADONLY but under the "Deprecated messages" section.
  3. Maybe there is some GTK+ level API that you can use to block user input but keep SciTE functional? Also, as a quick workaround you can call SCI_SETREADONLY(false) before using SCI_ADDTEXT and then again call SCI_SETREADONLY(true)
  4. Your expression is too complex, think simple, try this : https://regex101.com/r/WjCbT1/2
  5. @youtuber Ironically the first character after the first slash in your example URLs is a slash itself... (https://)
  6. @ramin92003 Great! It can be intimidating at first but you will get good at writing AutoIt after some practice
  7. @Ramin You are not properly using the If...ElseIf...EndIf statements, combine them like shown in the previous post by @mLipok and me. Currently no matter what, all of the If conditions are executed so you are guaranteed to hit a wrong "degree" error and then the program would exit.
  8. I polished up @mLipok's script to look more like what a normal AutoIt script would look like instead of being an exact translation Local $degree = InputBox("Enter the degree [BA / BSC / BIS / BBA] :", '') Local $name = "" Local $maxEnrollment = 80 If $degree = "BA" Or $degree = "BSC" Or $degree = "BIS" Or $degree = "BBA" Then If $degree = "BA" Then $name = "Department of Bachelor of Arts" ElseIf $degree = "BSC" Then $name = "Department of Bachelor of Science" ElseIf $degree = "BIS" Then $name = "Department of Information Systems" ElseIf $degree = "BBA" Then $name = "Department of Bachelor of Administration" Else ConsoleWrite(@CRLF & "INVALID DEGREE PROGRAM - PLEASE ENTER A NEW DEGREE PROGRAM") EndIf EndIf Few things to note: The equal operator can be used for both comparison and assignment in AutoIt, the meaning changes based on the context No string substitution is done in AutoIt, so you have to manually construct a string by the concatenation/joining operator (&) @CRLF is a special variable (called a macro) which is equal to /r/n in python string substitution. (@LF is equal to just \n) Most AutoIt development is done on a GUI basis rather than console-based input/output, ConsoleWrite is used for quick runtime debugging or to output fairly technical information, most of the time you would be using the MsgBox and InputBox functions to interact with the users. Don't under-estimate the awesome help file which is an all round reference to the AutoIt language, it comes installed with AutoIt and you can press F1 in SciTE to open it By the way welcome to AutoIt Forums.
  9. My pleasure, good luck!
  10. @Hitesh_Luthra I see, if you are working in a company you might try to convince your higher-ups to add an exception for BleachBit, it is free and open source software after all. It would be a lot better than something put together with UIAutomation and/or GUI automation.
  11. Are the 50-70+ GUI windows hand-made? You can always have multiple source files and have a single compiled file, this would be the ideal approach, but you will have to handle the design of the program so that no issue with include files arises.
  12. @Efo74 I have also found the VHDX specification, it says that the file header starts immediately and is 1024 bytes long (1 MB), so you can backup that to prevent VHDX from working in other programs
  13. Instead of using the propitiatory CCleaner (which is probably loaded with spyware and adware in the installers), use the much better free and open source BleachBit program to remove all sorts of junk, including passwords from various browsers! It also has a command-line interface so that you can totally avoid GUI automation
  14. For VHD (specification) you can just backup the first 512 bytes (copy of footer) and 1024 bytes (header) of the file and any sane program would not accept it as a proper VHD I imagine you could do something similar with VHDX too but I haven't looked into it
  15. Dude, my man. Calm down, you could have just tried to read the rules and follow them? This is a community, not your personal servants who obey your orders.
  16. The full SciTE4AutoIt3 package comes with SciTE config (which should be under the Tools menu), it can change various settings including the fonts used
  17. It is still not clear (ambiguous) if OP wants to change the password of a machine owned by Microsoft, thus I asked about more details on this "special RDP session". OP wouldn't be able to change the remote computer's password anyway if they are not authorized to do it, since the administrators would (hopefully) have disabled the related mechanisms.
  18. Can you elaborate on this "special web based RDP-Solution"? Do you have control over the remote computer? If yes, then maybe you can design a software solution to change the password without sending Ctrl+Alt+Delete, maybe a simple script which listens for a HotKey in the remote computer and launches the relevant password changing program.
  19. @mobin Yes, they are still in beta
  20. TheDcoder

    HTML FORM

    My pleasure @Daniza
  21. TheDcoder

    HTML FORM

    So the noodles are a category and the Shangai, Hong Kong, Empress noodles are the actual items? If that is the case then I think you can skip the input for noodles, just make it a container and put the noodles items in it. You can handle the value of noodles during updating the database (0 if no noodles have been request, else 1 according to your logic). JavaScript is pretty easy to bypass so you should always validate the input on the server side so that noodles doesn't have 1 with all the other noodles with value 0
  22. TheDcoder

    HTML FORM

    @Daniza You would have to use some JavaScript to make that happen, you can try reading these helpful resources and figure it out yourself: https://developer.mozilla.org/en-US/docs/Web/Events https://developer.mozilla.org/en-US/docs/Learn/HTML/Forms You can also show your HTML code so that maybe I can write a little example JavaScript for you P.S What do noodles have to do with Hong Kong or Shanghai?
  23. @jchd Understandable, I am in somewhat middle of the both arguments, I start simple and then if things start getting complex (like the log file example) I will rewrite the portion of it using something better suited There are also people like @TheSaint who would prefer to go all simple (key-value) even though it become somewhat complex in the end... All about choice and personal preference it seems, ultimately programmers (who know what they are doing) will choose the solution which is more maintainable to them P.S Looks like we have derailed this topic, not sure if it is a good idea to split the posts.
  24. I see, I didn't get that meaning from your posts before I agree, I am no fan of the hype bandwagon either. Any good developer worth their salt should know what to use according to their specific situation, in this case OP has not given any clear indication of how they are going to use it, but maybe the want a simple key-value datastore like Redis... I have personally never used a DB or datastore before, so I cannot go into the specifics, but it does look like SQL-like databases are somewhat overkill for small general purpose key-value databases, many projects of that sort never use the other fine tuned features of SQL (at-least that is how it looks like). Feel free to correct me if I am wrong
  25. That doesn't really make sense to me, it doesn't have to be an established model or "standard" to be non-proprietary. The code is free for anyone to use and modify etc. I don't see how this is related to Redis being a "proprietary" datastore, it is as you have said, one of the many solutions to certain situations, just like how other SQL-like databases are
×
×
  • Create New...