A method of removing the DOS black window when Matlab compiles the executable graphical interface program.

zhaozj2021-02-16  102

Source: http://www.simwe.com/cgi-bin/ut/topic_show.cgi? Id = 36244 & h = 1 & bpg = 2 & agn = -1

Written in front: The recent intrustments are relatively high. Everyone has taken out their own homes, or learn new things like hungry to solve some tricky problems that everyone encountered when actually use MATLAB. I personally think this is a phenomenon that is the healthy development of the forum based on technical discussion. This phenomenon is beneficial to everyone, whether it is posted, or watching it, it will get some gains. For me, spend your own spare time in browsing such a forum and participating in discussion, I will not regret it. There are a lot of the forum on the Internet, but there is not much characteristic, and pay attention to the technical discussion for less, I hope everyone will continue to maintain such enthusiasm, I hope Simwe better. Text: One of the latest forums is how to remove the black window generated when Matlab Plum compiled by Matlab Plum. This phenomenon mainly refers to the Windows platform. For example, the window of the black background that appears in the drawing. In this example, it is known that the file name is: myApp01.exe, which is compiled from the MATLAB program myApp01.m. In matlab, myApp01.m is a simple GUI program, with two buttons and a graphics on the interface. How to compile here without discussion in Matlab, after the myApp01.exe, if you run, the black window as shown in the drawings. Regarding how to remove the black window, now MathWorks has nothing to do. There are several ways to circulate: For example, the modification of the SCIE classmates presentation MATLAB has reached the method of removing that black window in the way MATLABs produced during the process of compiling the cannference file. In addition, some people in MathWorks also propose with free tool NSIS to make another executable file, which can start our executable, such as MyApp01.exe, but does not appear the black window. In fact, if it is just a simple to take out that black window, it may not be a good thing, because the window sometimes displays some useful information, such as some error messages generated by the program, or the program can also use it to generate some information in some running (With the DISP () function). I have another way here that uses a software written in advance to run executables generated by MATLAB such as myApp01.exe. Some information generated in myApp01.exe can also be captured and displayed in this Loader software. Document.body.clientWidth-300) {this.height = (Document.Body.ClientWidth-300) * this.height / this.width; this.width = document.body.clientwidth-300} "Border = 0> required The file is in the attachment, including 1.WGLoader.exe ---- Startup program, can run in Windows NT / 2000 / XP, but may not be able to run in Windows 98 / ME. Unzip to any path downtown 2. myapp01.zip ---- MATLAB compiles the executable and the necessary support files, unzipped to any path. The interface after the Attachment WGLoader runs as follows: The instructions are used in the figure.

Document.body.clientWidth-300) {this.height = (Document.body.ClientWidth-300) * this.height / this.width; this.width = document.body.clientwidth-300} "Border = 0>, for example, I decompressed myApp01.exe to the C: / Temp directory, then WGLoader can set this, document.body.clientwidth-300) {this.Height = (Document.body.clientwidth-300) * this.height / this. Width; this.width = document.body.clientwidth-300} "Border = 0> After starting myApp01, you can click" START "button, and the result can be obtained. Document.body.clientwidth-300) {this.height = (document.body.clientwidth-300) * this.height / this.width; this.width = document.body.clientwidth-300} "border = 0> Listen to CWIT Said, MATLAB's Legend function will have problems after compiling. I didn't pay attention to this problem before, so I have added a Legend call in MyApp01, but I didn't find problems after compilation, and the operation after compiled Legend is normal. For example, you can use the mouse toward other place. Document.body.clientwidth-300) {this.height = (Document.Body.ClientWidth-300) * this.Height / this.Width; this.width = Document.body.clientwidth -300} "Border = 0>

转载请注明原文地址:https://www.9cbs.com/read-10879.html

New Post(0)