<?xml version="1.0"?>
<rss version="2.0"><channel><title>Programming (C++, Delphi, VB/VBS, CMD/batch, etc.) Latest Topics</title><link>https://msfn.org/board/forum/66-programming-c-delphi-vbvbs-cmdbatch-etc/</link><description>Programming (C++, Delphi, VB/VBS, CMD/batch, etc.) Latest Topics</description><language>en</language><item><title>SET COPYCMD</title><link>https://msfn.org/board/topic/186786-set-copycmd/</link><description><![CDATA[<p>
	I have a basic question about MS-DOS batchfile: syntaxis of COPYCMD.
</p>

<p>
	Should I use:
</p>

<p>
	SET COPYCMD=/Y,V
</p>

<p>
	or 
</p>

<p>
	SET COPYCMD=/Y,/V
</p>

<p>
	or is there no difference and can I use both?
</p>

<p>
	BTW internet search gives no results in this case (for me).
</p>

<p>
	 
</p>
]]></description><guid isPermaLink="false">186786</guid><pubDate>Wed, 30 Apr 2025 11:21:40 +0000</pubDate></item><item><title>About a book on 80x86 Assembly</title><link>https://msfn.org/board/topic/186259-about-a-book-on-80x86-assembly/</link><description><![CDATA[<p>
	Hello!
</p>

<p>
	I've been wanting to learn some assembly programming and stumbled upon this book which some people mention it as a good introduction to 80x86 Assembly language.
</p>

<p>
	<a href="https://www.amazon.com/80X86-IBM-Compatible-Computers-Interfacing/dp/013061775X" rel="external nofollow">https://www.amazon.com/80X86-IBM-Compatible-Computers-Interfacing/dp/013061775X</a>
</p>

<p>
	The book is old, and I know that its contents are not updated to the newer processors from nowadays but as it involves old stuff I would like to give it a try (seems fun <img alt=":cool:" data-emoticon="" src="https://msfn.org/board/uploads/emoticons/default_cool.png" title=":cool:" />). To someone that knows about the book or about this subject the question I have is the following, which operating system do I use for DOS stuff? The book mentions the MASM assembler and there is some material on this website (archived by the Internet Archive) and mentions DOS (which is like an old Windows, I think <img alt=":P" data-emoticon="" src="https://msfn.org/board/uploads/emoticons/default_tongue.png" title=":P" />).
</p>

<p>
	<a href="https://web.archive.org/web/20090120232105/http://microdigitaled.com/x86/x86%20Books.htm" rel="external nofollow">https://web.archive.org/web/20090120232105/http://microdigitaled.com/x86/x86 Books.htm</a>
</p>

<p>
	I really don't know about this very much but I would like to. I think that I might be able to get stuff emulated on my system so I could follow the book.
</p>

<p>
	Also, if you know about a good way (or several ways) to follow this book, let me know! Seems like a very interesting journey.
</p>

<p>
	Cheers.
</p>

<p>
	PD: I don't know if this thread is in the correct place but as it has to do with assembly programming I figured it would fit well this category.
</p>
]]></description><guid isPermaLink="false">186259</guid><pubDate>Sun, 09 Jun 2024 16:14:45 +0000</pubDate></item><item><title>Agilia Partner for SCCM</title><link>https://msfn.org/board/topic/186110-agilia-partner-for-sccm/</link><description><![CDATA[<p>
	I am trying to install a application called (Agilia Partner) silently but its keep getting a pop up message(This software requires pdf reader), and when i click ok its closed and it is not installing silently. Could you please give some help. I have attached switches for the app and popup message screen shots herewith.
</p>

<p>
	I have tried different commands, 
</p>

<p>
	SetupAgilia Partner V2R 4.1.3 - 6.0.12 - Key2.exe" /VERYSILENT /SP- /LOADINF="C:\Users\JP\Desktop\New folder\sETUP.inf"
</p>

<p>
	"SetupAgilia Partner V2R 4.1.3 - 6.0.12 - Key2.exe" /SILENT /SUPPRESSMSGBOXES /LOADINF="C:\Users\JP\Desktop\New folder\sETUP.inf"
</p>

<p>
	 
</p>

<p>
	 
</p>

<p>
	 
</p>

<p>
	<a class="ipsAttachLink ipsAttachLink_image" href="https://msfn.org/board/uploads/monthly_2024_04/image.png.67f0c77703a0725513c3aaf865e00889.png" data-fileid="53975" data-fileext="png" rel=""><img class="ipsImage ipsImage_thumbnailed" data-fileid="53975" data-ratio="242.72" width="309" alt="image.thumb.png.e2ed97898692f2b59da020bd32b0815f.png" data-src="https://msfn.org/board/uploads/monthly_2024_04/image.thumb.png.e2ed97898692f2b59da020bd32b0815f.png" src="https://msfn.org/board/applications/core/interface/js/spacer.png" /></a><a class="ipsAttachLink ipsAttachLink_image" href="https://msfn.org/board/uploads/monthly_2024_04/image.png.8d6681e59ce6dc34d3edd9f30cfc87a3.png" data-fileid="53976" data-fileext="png" rel=""><img class="ipsImage ipsImage_thumbnailed" data-fileid="53976" data-ratio="20.50" width="1000" alt="image.thumb.png.05de38457c217773eab1b1a80b35d4ee.png" data-src="https://msfn.org/board/uploads/monthly_2024_04/image.thumb.png.05de38457c217773eab1b1a80b35d4ee.png" src="https://msfn.org/board/applications/core/interface/js/spacer.png" /></a>
</p>
]]></description><guid isPermaLink="false">186110</guid><pubDate>Tue, 09 Apr 2024 13:22:45 +0000</pubDate></item><item><title>i've made a script for batch downloading windows update files</title><link>https://msfn.org/board/topic/182403-ive-made-a-script-for-batch-downloading-windows-update-files/</link><description><![CDATA[<p>
	While i was downloading Windows XP updates from the Microsoft Update Catalog, i realized this task could be done much faster. For that reason, i decided to make a PowerShell script for batch downloading updates from a list, featuring filters for language, NT version and architecture.
</p>

<p>
	I'm aware there is already another GUI application with a similar purpose, but you might find this one more fitting for your context as it has some key differences, such as:
</p>

<p>
	- Focused on simplicity. Command-line operation only
</p>

<p>
	- Script available under a permissive license (<a href="https://unlicense.org/" rel="external nofollow">Unlicense</a>)
</p>

<p>
	- Code and its functioning is commented and documented to its best. Take a look at the code to learn how it works.
</p>

<p>
	- It can run natively on Linux, even on a Raspberry Pi
</p>

<p>
	- A function lets you download the details page in HTML format for each update, ready for offline read
</p>

<p>
	 
</p>

<p>
	I've made it available both on my website and GitHub:
</p>

<p>
	<a href="https://github.com/blueclouds8666/msupdate-dl" rel="external nofollow">https://github.com/blueclouds8666/msupdate-dl</a>
</p>

<p>
	<a href="http://neonfloppy.sytes.net/projects/msupdate-dl/" rel="external nofollow">http://neonfloppy.sytes.net/projects/msupdate-dl/</a>
</p>

<p>
	 
</p>

<p>
	Let me know if you found it useful, I'll be listening feedback to improve the script if needed.
</p>

<p><a href="https://msfn.org/board/uploads/monthly_2021_02/img1-fullres.png.45d62145d15f069151b2bc98705fa7fc.png" class="ipsAttachLink ipsAttachLink_image"><img data-fileid="46943" src="https://msfn.org/board/applications/core/interface/js/spacer.png" data-src="https://msfn.org/board/uploads/monthly_2021_02/img1-fullres.png.45d62145d15f069151b2bc98705fa7fc.png" data-ratio="75" width="1000" class="ipsImage ipsImage_thumbnailed" alt="img1-fullres.png"></a></p>]]></description><guid isPermaLink="false">182403</guid><pubDate>Sat, 13 Feb 2021 16:12:40 +0000</pubDate></item><item><title>Guide for compiling VirtualBox 4.3 and 5.2</title><link>https://msfn.org/board/topic/184983-guide-for-compiling-virtualbox-43-and-52/</link><description><![CDATA[<p>
	I have recently been investigating how to compile VirtualBox versions 4.3.12 and 5.2.34 on Windows, only to realize that the documentation is very incomplete and that many issues will prevent you from doing it successfully. It took me a long time, but i eventually got it working. Given the unnecessary and tedious complexities, i thought it was a good idea to document my findings and share them with the rest of you, so it is humanly possible to compile these two versions. I have published the necessary tools, libraries and instructions on my website so you can grab them conveniently from there.
</p>

<p>
	<a href="http://neonfloppy.sytes.net/resources/compiling/" rel="external nofollow">http://neonfloppy.sytes.net/resources/compiling/</a>
</p>
]]></description><guid isPermaLink="false">184983</guid><pubDate>Fri, 18 Aug 2023 14:14:36 +0000</pubDate></item><item><title>Dial Up Sounds C# with Internal Speaker</title><link>https://msfn.org/board/topic/182261-dial-up-sounds-c-with-internal-speaker/</link><description><![CDATA[<p>
	Hello, I want to use console.beep so that the internal speaker produces sounds similar to those of a telephone. I tried to make the dial up sound but it's a bit monophonic and I don't really know how to do it.
</p>

<p>
	 
</p>
]]></description><guid isPermaLink="false">182261</guid><pubDate>Sun, 10 Jan 2021 18:05:37 +0000</pubDate></item><item><title>how use Math for create 3D games?</title><link>https://msfn.org/board/topic/183818-how-use-math-for-create-3d-games/</link><description><![CDATA[<p>
	i need 1 correction: the screen only use 2D(X, Y) and not 3D(X, Y, Z)... so how can i create the perspective?
</p>

<p>
	is these math correct:
</p>

<p>
	PosX2D = PosX3D /(FocalDistance+PosZ3D);
</p>

<p>
	PosY2D = PosY3D /(FocalDistance+PosZ3D)
</p>

<p>
	?
</p>

<p>
	i have seen several tutorials and seems that they have their own Perspective.<br />
	understand these, i can create my own polygon and move front-back, and left-right.<br />
	<br />
	 
</p>
]]></description><guid isPermaLink="false">183818</guid><pubDate>Sun, 07 Aug 2022 10:45:33 +0000</pubDate></item><item><title><![CDATA[VB 5.0 / VB.NET | The shorcuts on the desktop & the Start menu does not have the right folder in their targets]]></title><link>https://msfn.org/board/topic/184807-vb-50-vbnet-the-shorcuts-on-the-desktop-the-start-menu-does-not-have-the-right-folder-in-their-targets/</link><description><![CDATA[<p>
	Hello!
</p>

<p>
	I have a <strong>big </strong>issue in Visual Basic. When I create a shortcut on the desktop using a small program in Visual Basic 5.0 on Windows 98, the shortcut have its target on the previous folder (ex: C:\Program Files\ovtxt_xp_run.exe instead of C:\Program Files\OverRender OverText XP\ovtxt_xp_run.exe | you can see that the "OverRender OverText XP" folder is missing in the target.
</p>

<p>
	Here's the code in VB 5.0:
</p>

<pre class="ipsCode prettyprint lang-c prettyprinted"><span class="str">' Programme de création du raccourci d'</span><span class="typ">OverRender</span><span class="pln"> </span><span class="typ">OverText</span><span class="pln"> XP dans le dossier de l</span><span class="str">'</span><span class="pln">application
</span><span class="str">'</span><span class="pln"> </span><span class="typ">This</span><span class="pln"> program is a part of the </span><span class="typ">OverRender</span><span class="pln"> </span><span class="typ">OverText</span><span class="pln"> XP </span><span class="typ">Setup</span><span class="pun">.</span><span class="pln">
</span><span class="str">'</span><span class="pln">
</span><span class="str">'</span><span class="pln"> </span><span class="lit">2023</span><span class="pln"> </span><span class="pun">-</span><span class="pln"> </span><span class="typ">OverRender</span><span class="pun">.</span><span class="pln">com

</span><span class="str">'</span><span class="pln"> </span><span class="typ">Processus</span><span class="pln"> de cr</span><span class="pun">é</span><span class="pln">ation du raccourci

</span><span class="typ">Private</span><span class="pln"> </span><span class="typ">Sub</span><span class="pln"> cmdMakeLNKFile</span><span class="pun">()</span><span class="pln">
</span><span class="typ">Dim</span><span class="pln"> </span><span class="typ">Shell</span><span class="pln"> </span><span class="typ">As</span><span class="pln"> </span><span class="typ">WshShell</span><span class="pln">
</span><span class="typ">Dim</span><span class="pln"> </span><span class="typ">Shortcut</span><span class="pln"> </span><span class="typ">As</span><span class="pln"> </span><span class="typ">WshShortcut</span><span class="pln">
</span><span class="typ">Dim</span><span class="pln"> </span><span class="typ">DesktopDir</span><span class="pln"> </span><span class="typ">As</span><span class="pln"> </span><span class="typ">String</span><span class="pln">
  </span><span class="str">' Initialiser l'</span><span class="pln">objet </span><span class="typ">WshShell</span><span class="pln">
  </span><span class="typ">Set</span><span class="pln"> objShell </span><span class="pun">=</span><span class="pln"> </span><span class="typ">New</span><span class="pln"> </span><span class="typ">WshShell</span><span class="pln">

  </span><span class="str">' Initialiser l'</span><span class="pln">objet </span><span class="typ">ObjShortcut</span><span class="pln">
  </span><span class="str">'</span><span class="pln">the complete name of the </span><span class="pun">.</span><span class="pln">lnk file</span><span class="pun">,</span><span class="pln"> include full path plus the </span><span class="pun">.</span><span class="pln">LNK file extension
  </span><span class="typ">Set</span><span class="pln"> objshortcut </span><span class="pun">=</span><span class="pln"> objShell</span><span class="pun">.</span><span class="typ">CreateShortcut</span><span class="pun">(</span><span class="typ">App</span><span class="pun">.</span><span class="typ">Path</span><span class="pln"> </span><span class="pun">+</span><span class="pln"> </span><span class="str">"/OverRender OverText XP.lnk"</span><span class="pun">)</span><span class="pln">

  </span><span class="str">'</span><span class="pln"> D</span><span class="pun">é</span><span class="pln">finir la cible du raccourci
  objshortcut</span><span class="pun">.</span><span class="typ">TargetPath</span><span class="pln"> </span><span class="pun">=</span><span class="pln"> </span><span class="typ">App</span><span class="pun">.</span><span class="typ">Path</span><span class="pln"> </span><span class="pun">+</span><span class="pln"> </span><span class="str">"/ovtxt_xp_run.exe"</span><span class="pln">
  
  </span><span class="str">' Définir l'</span><span class="pln">ic</span><span class="pun">ô</span><span class="pln">ne du raccourci
  objshortcut</span><span class="pun">.</span><span class="typ">IconLocation</span><span class="pln"> </span><span class="pun">=</span><span class="pln"> </span><span class="typ">App</span><span class="pun">.</span><span class="typ">Path</span><span class="pln"> </span><span class="pun">+</span><span class="pln"> </span><span class="str">"/softassets/ovtexticon.ico"</span><span class="pln">
  
  </span><span class="str">'</span><span class="pln"> D</span><span class="pun">é</span><span class="pln">finir le commentaire </span><span class="pun">/</span><span class="pln"> la description du raccourci
  objshortcut</span><span class="pun">.</span><span class="typ">Description</span><span class="pln"> </span><span class="pun">=</span><span class="pln"> </span><span class="str">"Create, open, edit and share documents easily by using OverRender OverText XP."</span><span class="pln">
  </span><span class="str">'</span><span class="pln"> </span><span class="typ">Sauvegarder</span><span class="pln"> le raccourci cr</span><span class="pun">éé</span><span class="pln">
  objshortcut</span><span class="pun">.</span><span class="typ">Save</span><span class="pln">
  </span><span class="typ">MsgBox</span><span class="pln"> </span><span class="pun">(</span><span class="typ">App</span><span class="pun">.</span><span class="typ">Path</span><span class="pun">)</span><span class="pln">
</span><span class="typ">End</span><span class="pln"> </span><span class="typ">Sub</span><span class="pln">

</span><span class="str">'</span><span class="pln"> </span><span class="typ">Ex</span><span class="pun">é</span><span class="pln">cution de la t</span><span class="pun">â</span><span class="pln">che </span><span class="str">"cmdMakeLNKFile"</span><span class="pln"> lors du lancement du programme</span><span class="pun">.</span><span class="pln">
</span><span class="str">'</span><span class="pln"> A noter </span><span class="pun">:</span><span class="pln"> le programme est invisible</span><span class="pun">.</span><span class="pln">
</span><span class="typ">Private</span><span class="pln"> </span><span class="typ">Sub</span><span class="pln"> </span><span class="typ">Form_Load</span><span class="pun">()</span><span class="pln">
</span><span class="typ">Call</span><span class="pln"> cmdMakeLNKFile
</span><span class="str">'</span><span class="typ">MsgBox</span><span class="pln"> </span><span class="pun">(</span><span class="typ">DesktopPath</span><span class="pun">)</span><span class="pln">
</span><span class="typ">End</span><span class="pln">
</span><span class="typ">End</span><span class="pln"> </span><span class="typ">Sub</span><span class="pln">
</span></pre>

<p>
	(do not worry about the comments in French, you can always translate them).
</p>

<p>
	Could anyone help me with that please?
</p>

<p>
	I have that since now 1 year and it's very annoying, as shortcuts are made to make the access to the program easy and not hard.
</p>

<p>
	Thank you!
</p>
]]></description><guid isPermaLink="false">184807</guid><pubDate>Fri, 02 Jun 2023 17:51:31 +0000</pubDate></item><item><title>could someone help with a complex search and replace query? (gsar or sed for Windows)</title><link>https://msfn.org/board/topic/183743-could-someone-help-with-a-complex-search-and-replace-query-gsar-or-sed-for-windows/</link><description><![CDATA[<p>
	Hi there!
</p>

<p>
	I am working on a conversion script but got stuck with 1 thing that I cannot get past... <br />
	I want to change a certain word in a file with a hex-value, with the use of gsar.exe (command line!), but ignore it if the word is somewhere between quotes<br />
	<br />
	<strong>Original text:</strong><br />
	9023 AAAA "this is a AAAA" "AAAA" "*:;AAAA'" Aaaa " Because AAAA" " aaaa " AaAa<br />
	<br />
	<strong>text after gsar is done:</strong><br />
	9023 <strong>XXXX</strong> "this is a AAAA" "AAAA" "*:;AAAA'" <strong>XXXX</strong> " Because AAAA" " aaaa " <strong>XXXX</strong><br />
	<br />
	(where XXXX represents the hex value a5)<br />
	<br />
	Please note:<br />
	-it should be case insensitive<br />
	-it should ignore everything between quotes<br />
	-I want to use gsar.exe but sed.exe (Windows) or another command line tool would be good as well<br />
	-The opening quotes are the same as the closing quotes (0x22)<br />
	<br />
	I have been working on this for a whole day now and I am not even close <img alt=":P" data-emoticon="" src="https://msfn.org/board/uploads/emoticons/default_tongue.png" title=":P" /><br />
	<br />
	I know this be done and probably with only 1 line. This is what makes it extra frustrating. It doesn't have to be gsar. Sed.exe or another command line tool would be good as well! <br />
	 
</p>
]]></description><guid isPermaLink="false">183743</guid><pubDate>Sun, 10 Jul 2022 06:32:00 +0000</pubDate></item><item><title><![CDATA[[PS&CMD] My short code line will not work if a folder/file name has an "&" character in it.]]></title><link>https://msfn.org/board/topic/183619-pscmd-my-short-code-line-will-not-work-if-a-folderfile-name-has-an-character-in-it/</link><description><![CDATA[<p>
	Hi,<br />
	I  have a short  code line that would ask elevated privileges for a Batch file. But now I noticed that if a file name or a folder name has an "&amp;" character in it then the code will not work. <span class="ipsEmoji">😫</span><br />
	Dose anyone have a solution for this problem? <span class="ipsEmoji">🤔</span>
</p>

<pre class="ipsCode prettyprint lang-html prettyprinted"><span class="pln">@ECHO OFF
FLTMC &gt;NUL 2&gt;&amp;1 || PowerShell Start-Process -FilePath '%0' -Verb RunAs &gt;NUL 2&gt;&amp;1 &amp;&amp; EXIT /b
FLTMC &gt;NUL 2&gt;&amp;1 &amp;&amp; GoTo EVD
ECHO I'm not wokring.
PAUSE
:EVD
ECHO Hallo World.
PAUSE</span></pre>

<p>
	 
</p>
]]></description><guid isPermaLink="false">183619</guid><pubDate>Sun, 29 May 2022 05:37:54 +0000</pubDate></item><item><title>Simple script to launch a few programs and position their window and size on the correct display</title><link>https://msfn.org/board/topic/183504-simple-script-to-launch-a-few-programs-and-position-their-window-and-size-on-the-correct-display/</link><description><![CDATA[<p>
	So I want to write basically a start-up script to start up Task Manager, Resource Manager, Core Temp, and MSI Afterburner on my secondary display.
</p>

<p>
	I remember back in the old XP days there was a Window menu and you could tell it to remember the size and position (or maybe that Win98?)
</p>

<p>
	Anyways, I'm not sure which language to implement this.
</p>

<p>
	The way I see it I can use:
</p>

<p>
	- Windows Batch script (.bat)
</p>

<p>
	- VBscript (.vbs) - I know this may be considered outdated but it's still very useful and can do the simple task I need
</p>

<p>
	- Powershell
</p>

<p>
	- .NET (probably overkill but listing anyways)
</p>

<p>
	And I'm sure there's more options I haven't listed.
</p>

<p>
	If there is a "preferred" or "best-practice" choice I would like to know
</p>

<p>
	Or if you just have suggestions or comments please leave a remark below!
</p>

<p>
	I have same basic experience in all the above languages so that's not a factor.
</p>

<p>
	RIght now I am considering writing the same script with the first 3 languages and noting my opinions/observations.
</p>
]]></description><guid isPermaLink="false">183504</guid><pubDate>Thu, 14 Apr 2022 23:22:33 +0000</pubDate></item><item><title>Do any Visual C++ versions have telemetry?</title><link>https://msfn.org/board/topic/183475-do-any-visual-c-versions-have-telemetry/</link><description><![CDATA[<p>
	My research indicates telemetry was added in the 2015 version, and then removed in an update soon after.
</p>

<p>
	I have not found anything about telemetry being present in the 2015 (updated version) and beyond but I just wanted to check here - is this correct?
</p>
]]></description><guid isPermaLink="false">183475</guid><pubDate>Fri, 01 Apr 2022 20:24:42 +0000</pubDate></item><item><title>[PS/Batch] Looking for a one line command to Refresh the Desktop.</title><link>https://msfn.org/board/topic/183371-psbatch-looking-for-a-one-line-command-to-refresh-the-desktop/</link><description><![CDATA[<p>
	Hi,<br />
	I'm looking for a one line command that would Refresh the Desktop or send the F5 key to the Desktop. Would that be possible with PowerShell or in Batch?
</p>
]]></description><guid isPermaLink="false">183371</guid><pubDate>Sat, 05 Mar 2022 17:15:47 +0000</pubDate></item><item><title>How to get data from C++ program memory in Python</title><link>https://msfn.org/board/topic/182934-how-to-get-data-from-c-program-memory-in-python/</link><description><![CDATA[<p>
	The C++ program produces an array, I want to put this array into python to do some operations, and then the data processed by python is returned to the C++ program for further processing.<br />
	How do I do this?
</p>
]]></description><guid isPermaLink="false">182934</guid><pubDate>Fri, 20 Aug 2021 03:59:29 +0000</pubDate></item><item><title>Why can't I print out data?</title><link>https://msfn.org/board/topic/182899-why-cant-i-print-out-data/</link><description><![CDATA[<pre class="ipsCode prettyprint lang-c prettyprinted"><span class="com">#include</span><span class="pln">
</span><span class="kwd">using</span><span class="pln"> </span><span class="kwd">namespace</span><span class="pln"> std</span><span class="pun">;</span><span class="pln">
</span><span class="kwd">struct</span><span class="pln"> node
</span><span class="pun">{</span><span class="pln">
</span><span class="kwd">struct</span><span class="pln"> node</span><span class="pun">*</span><span class="pln"> head</span><span class="pun">;</span><span class="pln">
</span><span class="typ">int</span><span class="pln"> date</span><span class="pun">;</span><span class="pln">
</span><span class="kwd">struct</span><span class="pln"> node</span><span class="pun">*</span><span class="pln"> later</span><span class="pun">;</span><span class="pln">

</span><span class="pun">};</span><span class="pln">
</span><span class="kwd">struct</span><span class="pln"> node</span><span class="pun">*</span><span class="pln"> headnode</span><span class="pun">()</span><span class="com">//Create table header</span><span class="pln">
</span><span class="pun">{</span><span class="pln">
</span><span class="kwd">struct</span><span class="pln"> node</span><span class="pun">*</span><span class="pln"> head </span><span class="pun">=</span><span class="pln"> </span><span class="kwd">new</span><span class="pln"> </span><span class="kwd">struct</span><span class="pln"> node</span><span class="pun">;</span><span class="pln">
head</span><span class="pun">-&gt;</span><span class="pln">head </span><span class="pun">=</span><span class="pln"> head</span><span class="pun">;</span><span class="pln">
head</span><span class="pun">-&gt;</span><span class="pln">later </span><span class="pun">=</span><span class="pln"> head</span><span class="pun">;</span><span class="pln">
</span><span class="kwd">return</span><span class="pln"> head</span><span class="pun">;</span><span class="pln">
</span><span class="pun">}</span><span class="pln">
</span><span class="com">//Node</span><span class="pln">
</span><span class="kwd">struct</span><span class="pln"> node</span><span class="pun">*</span><span class="pln"> headnode</span><span class="pun">(</span><span class="typ">int</span><span class="pln"> dat</span><span class="pun">)</span><span class="pln">
</span><span class="pun">{</span><span class="pln">
</span><span class="kwd">struct</span><span class="pln"> node</span><span class="pun">*</span><span class="pln"> headnode </span><span class="pun">=</span><span class="pln"> </span><span class="kwd">new</span><span class="pln"> </span><span class="kwd">struct</span><span class="pln"> node</span><span class="pun">;</span><span class="pln">
headnode</span><span class="pun">-&gt;</span><span class="pln">date </span><span class="pun">=</span><span class="pln"> dat</span><span class="pun">;</span><span class="pln">
headnode</span><span class="pun">-&gt;</span><span class="pln">head </span><span class="pun">=</span><span class="pln"> NULL</span><span class="pun">;</span><span class="pln">
headnode</span><span class="pun">-&gt;</span><span class="pln">later </span><span class="pun">=</span><span class="pln"> NULL</span><span class="pun">;</span><span class="pln">
</span><span class="kwd">return</span><span class="pln"> headnode</span><span class="pun">;</span><span class="pln">

</span><span class="pun">}</span><span class="pln">
</span><span class="com">//</span><span class="pln">
</span><span class="kwd">void</span><span class="pln"> print</span><span class="pun">(</span><span class="kwd">struct</span><span class="pln"> nodehead</span><span class="pun">,</span><span class="typ">int</span><span class="pln"> date</span><span class="pun">)</span><span class="com">//Head insertion method</span><span class="pln">
</span><span class="pun">{</span><span class="pln">
</span><span class="kwd">struct</span><span class="pln"> node newhead </span><span class="pun">=</span><span class="pln"> headnode</span><span class="pun">(</span><span class="pln">date</span><span class="pun">);</span><span class="pln">
newhead</span><span class="pun">-&gt;</span><span class="pln">head </span><span class="pun">=</span><span class="pln"> head</span><span class="pun">;</span><span class="pln">
newhead</span><span class="pun">-&gt;</span><span class="pln">later </span><span class="pun">=</span><span class="pln"> head</span><span class="pun">-&gt;</span><span class="pln">later</span><span class="pun">;</span><span class="pln">
head</span><span class="pun">-&gt;</span><span class="pln">later</span><span class="pun">-&gt;</span><span class="pln">head </span><span class="pun">=</span><span class="pln"> newhead</span><span class="pun">;</span><span class="pln">
newhead</span><span class="pun">-&gt;</span><span class="pln">later </span><span class="pun">=</span><span class="pln"> newhead</span><span class="pun">;</span><span class="pln">
</span><span class="pun">}</span><span class="pln">
</span><span class="kwd">void</span><span class="pln"> printf</span><span class="pun">(</span><span class="kwd">struct</span><span class="pln"> node</span><span class="pun">*</span><span class="pln"> head</span><span class="pun">)</span><span class="com">//print</span><span class="pln">
</span><span class="pun">{</span><span class="pln">
</span><span class="kwd">struct</span><span class="pln"> node</span><span class="pun">*</span><span class="pln"> newnode </span><span class="pun">=</span><span class="pln"> head</span><span class="pun">-&gt;</span><span class="pln">later</span><span class="pun">;</span><span class="pln">
</span><span class="kwd">while</span><span class="pun">(</span><span class="pln">newnode </span><span class="pun">!=</span><span class="pln"> head</span><span class="pun">)</span><span class="pln">
</span><span class="pun">{</span><span class="pln">
cout </span><span class="pun">&lt;&lt;</span><span class="pln"> newnode</span><span class="pun">-&gt;</span><span class="pln">date </span><span class="pun">&lt;&lt;</span><span class="pln"> endl</span><span class="pun">;</span><span class="pln">
newnode </span><span class="pun">=</span><span class="pln"> newnode</span><span class="pun">-&gt;</span><span class="pln">head</span><span class="pun">;</span><span class="pln">
</span><span class="pun">}</span><span class="pln">
</span><span class="pun">}</span><span class="pln">
</span><span class="typ">int</span><span class="pln"> main</span><span class="pun">()</span><span class="pln">
</span><span class="pun">{</span><span class="pln">
</span><span class="kwd">struct</span><span class="pln"> node</span><span class="pun">*</span><span class="pln"> head </span><span class="pun">=</span><span class="pln"> headnode</span><span class="pun">();</span><span class="pln">
print</span><span class="pun">(</span><span class="pln">head</span><span class="pun">,</span><span class="pln"> </span><span class="lit">44</span><span class="pun">);</span><span class="pln">
print</span><span class="pun">(</span><span class="pln">head</span><span class="pun">,</span><span class="pln"> </span><span class="lit">33</span><span class="pun">);</span><span class="pln">
print</span><span class="pun">(</span><span class="pln">head</span><span class="pun">,</span><span class="pln"> </span><span class="lit">22</span><span class="pun">);</span><span class="pln">
printf</span><span class="pun">(</span><span class="pln">head</span><span class="pun">);</span><span class="pln">
cout </span><span class="pun">&lt;&lt;</span><span class="pln"> </span><span class="str">"Really hard"</span><span class="pln"> </span><span class="pun">&lt;&lt;</span><span class="pln"> endl</span><span class="pun">;</span><span class="pln">
system</span><span class="pun">(</span><span class="str">"pause"</span><span class="pun">);</span><span class="pln">
</span><span class="kwd">return</span><span class="pln"> </span><span class="lit">0</span><span class="pun">;</span><span class="pln">
</span><span class="pun">}</span></pre>

<p>
	 
</p>
]]></description><guid isPermaLink="false">182899</guid><pubDate>Wed, 28 Jul 2021 09:05:35 +0000</pubDate></item><item><title>Get XP application to work on Windows 7+</title><link>https://msfn.org/board/topic/181824-get-xp-application-to-work-on-windows-7/</link><description><![CDATA[<p>
	I was wondering if someone with programming skills could help me to get an application to work on Windows 7 and newer.
</p>

<p>
	The problem with the application is that it crashes whenever you try to open or save a file (using the open/save dialog). It's a problem that also occurs with newer versions of this application and the fix seems to be to edit a file named CommonVcPh.dll and redirect comdlg32.dll to the XP version of this file (which you then copy to the folder the application resides in). I've tried that with the older version of this application but it still crashes whenever it's supposed to open the open/save dialog.
</p>

<p>
	<a href="https://workupload.com/file/Zn4cMQ27R65" rel="external nofollow">https://workupload.com/file/Zn4cMQ27R65</a>
</p>

<p>
	 
</p>

<p>
	P.S: DEP needs to be disabled to run the application.
</p>
]]></description><guid isPermaLink="false">181824</guid><pubDate>Thu, 27 Aug 2020 01:28:47 +0000</pubDate></item><item><title>Batch script start up from RunOnce registry fails !</title><link>https://msfn.org/board/topic/162906-batch-script-start-up-from-runonce-registry-fails/</link><description><![CDATA[
<p>Hi, Im trying to make a batch file, that installs a bunch of applications silently, and works awesome on Windows XP, but WIndows 7 with UAC Enabled is problem, I tryed a lot of tricks to bypass it, and failed !</p><p>However Im trying to Disable Windows UAC with this line of batch code !</p><p></p><div></div><pre class="ipsCode">reg add HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System /v DisableUAC /t REG_DWORD /d 0 /f</pre><p></p><p>And works perfectly, since to take effect machine must reboot, and it's not good choice since bypassing UAC would make all work easier, and I add another reg key to RunOnce, when machine starts up, launch that .bat file which installs silently applications !</p><p></p><div></div><pre class="ipsCode"><br>set BATDIR=%~dp0<br>reg add HKCU\Software\Microsoft\Windows\CurrentVersion\RunOnce /f /v One_Click_Installer /t REG_SZ /d "%BATDIR%win7.bat"<br>shutdown -r -f -t 5 -c "Machine will reboot within 5 sec's !"</pre><p></p><p>And it reboots, on startup launches win7.bat, which is batch file containing code to start installing applications, but I don't know whats the difference launchin this bat file on startup, it doesnt work, it's like just showing for example 'application x installed finished' but actually it's going fast to all applications but it doesnt work, when I double click to the same batch file, works perfeclty !</p><p>If you want I can post that .bat file code, win7.bat  .</p><p>So I just want to know, whats the difference, when same batch file launched directly works, when it starts up with RunOnce registry fails ?</p><p>If anyone has any trick that can run batch file, that executes exe's silently bypassing UAC, would be good to tell me !</p><p>Thanks !</p>
]]></description><guid isPermaLink="false">162906</guid><pubDate>Fri, 10 May 2013 17:25:30 +0000</pubDate></item><item><title>There is a possibility to play Microsoft Internet games for Windows XP/ME again !!</title><link>https://msfn.org/board/topic/182291-there-is-a-possibility-to-play-microsoft-internet-games-for-windows-xpme-again/</link><description><![CDATA[<p>
	<span><a contenteditable="false" data-ipshover="" data-ipshover-target="https://msfn.org/board/profile/424412-win32/?do=hovercard" data-mentionid="424412" href="https://msfn.org/board/profile/424412-win32/" rel="">@win32</a> <a contenteditable="false" data-ipshover="" data-ipshover-target="https://msfn.org/board/profile/423595-ximonite/?do=hovercard" data-mentionid="423595" href="https://msfn.org/board/profile/423595-ximonite/" rel="">@Ximonite</a> <a contenteditable="false" data-ipshover="" data-ipshover-target="https://msfn.org/board/profile/315141-jumper/?do=hovercard" data-mentionid="315141" href="https://msfn.org/board/profile/315141-jumper/" rel="">@jumper</a> and for everyone who understands the IDA language</span>
</p>

<p>
	HI , i finally found the solution. But implementing it is not easy.
</p>

<p>
	I am not a programming specialist, but I always look at it. In fact, the server does not contain source code and his mission was to link the players only. The source code is fully found in chkr.dll and chkrres.dll.<br />
	The source code is extracted using IDA hex rays Decompiler and all the game pictures are in chkrzm.exe and we extract them using Resource Hacker<br />
	This is an example of a game checkers.
</p>

<p>
	Therefore, I call on all programming specialists to cancel and reduce the obligation to enter the server. So the starting point becomes based on the code only.
</p>

<p>
	My grandfather wants these games. He almost gets Alzheimer after leaving the computer when these games are over. I promised him that I would find a solution, as he does not want another.
</p>

<p>
	Please help me.
</p>

<p>
	And whoever tries, I tell him, "Please do not change the appearance of the game."
</p>

<p>
	All source is in .dll<br />
	I found it all with IDA and ResourcesHacker.
</p>

<p>
	cmnresm.dll contains all the windows dialogs, all the menus windows and games bitmap and also contains STRINGTABLE.
</p>

<p>
	cmnclim.dll contains some DIALOG and Menus windows
</p>

<p>
	chckrres .dll contains configs, all game bitmap, icons, and DIALOG windows.
</p>

<p>
	chkr.dll contain the source code. I found the special functions of the game with using IDA
</p>

<p>
	This is an example of checkers
</p>

<p>
	And thanks.
</p>
]]></description><guid isPermaLink="false">182291</guid><pubDate>Fri, 15 Jan 2021 22:44:15 +0000</pubDate></item><item><title>Mingw32 Toolchain which uses CRTDLL.DLL instead of MSVCRT.DLL (C++ for Pre-2000)</title><link>https://msfn.org/board/topic/182195-mingw32-toolchain-which-uses-crtdlldll-instead-of-msvcrtdll-c-for-pre-2000/</link><description><![CDATA[<p>
	Earlier versions of Windows come with CRTDLL.DLL, but not MSVCRT.DLL
</p>

<p>
	With a few minor patches to GCC it's possible to make it link against CRTDLL.DLL by default instead of MSVCRT.DLL. This means when you compile using the patched toolchain your program assuming it uses no features only available on newer versions of Windows will automatically work on older versions of Windows such as NT 3.51.
</p>

<p>
	By using the files from Mingw32 instead of Mingw-w64 it resolved an issue where DLLs would have a .tls section and LoadLibrary would fail on Windows 95 or it would cause crashing on Windows 98 or Windows 2000. I put C++ for pre-2000 in the title because I also patched out a few functions in libstdc++ which require Windows 2000 or later.
</p>

<p>
	If you are running Arch Linux you can checkout the PKGBUILD files. <a href="https://github.com/ComputerNerd/mingw32-crtdll" rel="external nofollow">https://github.com/ComputerNerd/mingw32-crtdll</a>
</p>

<p>
	If you are not a Linux person but want to use this, you can run Arch Linux using a Virtual Machine or look at the PKGBUILD files and run them manually.
</p>
]]></description><guid isPermaLink="false">182195</guid><pubDate>Fri, 18 Dec 2020 06:13:43 +0000</pubDate></item><item><title>BACTH - set folder within folder as variable ?</title><link>https://msfn.org/board/topic/181850-bacth-set-folder-within-folder-as-variable/</link><description><![CDATA[<p>
	so heres my problem;
</p>

<p>
	in this specific case, but would be nice even for any future problem in any way...<br>
	<br>
	waterfox profile folder is this:<br>
	<strong>"%HOMEDRIVE%%HOMEPATH%\AppData\Local\Waterfox\Profiles"</strong>
</p>

<p>
	but on every new pc the default user profile folder is garbled mesh and always different generated<br>
	in my current install it is named <strong>c5prw4uk.default</strong><br>
	(so full path is "%HOMEDRIVE%%HOMEPATH%\AppData\Local\Waterfox\Profiles\c5prw4uk.default")<br>
	<br>
	my question is, how to make within BAT/CMD script, so when you do DIR /A:D (to show only directories)<br>
	that name of that folder which is displayed gets set in %variable so i can do cleaning of<br>
	<strong>c5prw4uk.default\cache\*.*</strong><br>
	<br>
	anyone understood ? <span><img alt=":D" data-emoticon="" src="https://msfn.org/board/applications/core/interface/js/spacer.png" title=":D" data-src="https://msfn.org/board/uploads/emoticons/default_biggrin.png"></span>
</p>
]]></description><guid isPermaLink="false">181850</guid><pubDate>Thu, 03 Sep 2020 15:54:34 +0000</pubDate></item><item><title>Install Windows 10 from a USB key with a batch file</title><link>https://msfn.org/board/topic/181669-install-windows-10-from-a-usb-key-with-a-batch-file/</link><description><![CDATA[<p>
	Hi,
</p>

<p>
	My project is how to create a batch file with a boot menu offering the possibility of installing the following operating system at the user's choice: Windows 10 alone or Windows 10 with preinstalled applications.
</p>

<p>
	A menu will allow the user of this medium to choose his hard disk from the disks installed on the workstation. The following disks may be encountered: 120 GB, 200 GB, 450 GB, 1 TB and 2 TB. 
</p>

<p>
	Among the intern's workstation applications we have: Vmware, Teamviewer, Vnc, Camtasia, Acrobatpdf.
</p>

<p>
	Is it possible to any help to build it?
</p>

<p>
	 
</p>

<p>
	Regards,
</p>

<p>
	 
</p>

<p>
	Shindenryu
</p>
]]></description><guid isPermaLink="false">181669</guid><pubDate>Thu, 09 Jul 2020 21:16:55 +0000</pubDate></item><item><title>storahci compile for XP</title><link>https://msfn.org/board/topic/181694-storahci-compile-for-xp/</link><description><![CDATA[<p>
	Can anyone compile this storahci driver sample but target XP?
</p>

<p>
	<u><span style="color:#000000;">https://github .com/Microsoft/Windows-driver-samples/tree/ </span><a href="https://www.flyingtogether.me/united-intranet-login/" rel="external nofollow"><span style="color:#000000;">United Intranet</span></a><span style="color:#000000;"> /master/storage//miniports/storahci</span></u>
</p>
]]></description><guid isPermaLink="false">181694</guid><pubDate>Sun, 19 Jul 2020 11:31:56 +0000</pubDate></item><item><title>Easy Way to Generate MD5 of File or Folder</title><link>https://msfn.org/board/topic/180935-easy-way-to-generate-md5-of-file-or-folder/</link><description><![CDATA[<p>
	I had found a very small and fast program to generate md5 files for files or folders a long time ago, discussed here - <a href="https://msfn.org/board/topic/162476-looking-for-a-vbs-script-to-generate-md5-of-a-file/page/2/?tab=comments#comment-1034865" rel="">https://msfn.org/board/topic/162476-looking-for-a-vbs-script-to-generate-md5-of-a-file/page/2/?tab=comments#comment-1034865</a> - and mentioned here - <a href="https://msfn.org/board/topic/180747-possible-to-do-this-batch-without-using-a-temporary-file/page/2/?tab=comments#comment-1175225" rel="">https://msfn.org/board/topic/180747-possible-to-do-this-batch-without-using-a-temporary-file/page/2/?tab=comments#comment-1175225</a>, but I couldn't remember where I got it. <a contenteditable="false" data-ipshover="" data-ipshover-target="https://msfn.org/board/profile/25215-jaclaz/?do=hovercard" data-mentionid="25215" href="https://msfn.org/board/profile/25215-jaclaz/" rel="">@jaclaz</a>had found an extremely similar one, but its author was also unknown.
</p>

<p>
	Well, I finally figured out where it came from. It is part of a distribution of hashutils - <a href="https://code.kliu.org/misc/hashutils/" rel="external">https://code.kliu.org/misc/hashutils/</a> - made and distributed by Kai Kliu -aka- code65536, so it can definitely be trusted. The version I was using was from hashutils-1.2.3-redist.7z, which is no longer posted on his site, while I assume the one that<a contenteditable="false" data-ipshover="" data-ipshover-target="https://msfn.org/board/profile/25215-jaclaz/?do=hovercard" data-mentionid="25215" href="https://msfn.org/board/profile/25215-jaclaz/" rel="">@jaclaz</a>found was either from hashutils-1.2.4-redist.7z or hashutils-1.3.0-redist.7z, both of which ARE available and readily downloadable.
</p>

<p>
	The components of the hashutils package are:
</p>

<ul>
	<li>
		crc32sum.exe
	</li>
	<li>
		md4sum.exe
	</li>
	<li>
		md5sum.exe
	</li>
	<li>
		sha1sum.exe
	</li>
	<li>
		edksum.exe
	</li>
</ul>

<p>
	All are available in both x86 and x64 versions (all included in the distribution), all of the utilities support recursive directory traversals with the -r switch, and all work on XP and above.
</p>

<p>
	<a contenteditable="false" data-ipshover="" data-ipshover-target="https://msfn.org/board/profile/25215-jaclaz/?do=hovercard" data-mentionid="25215" href="https://msfn.org/board/profile/25215-jaclaz/" rel="">@jaclaz</a>determined that md5sum.exe was as fast as any other method that was found at the time, and I believe the other utilities should have the same level of performance.
</p>

<p>
	Where this came from has been bugging me for over six years, so I figured I would pass this info along since I finally found it again. <span><img alt=":)" data-emoticon="" src="https://msfn.org/board/applications/core/interface/js/spacer.png" title=":)" data-src="https://msfn.org/board/uploads/emoticons/default_smile.png"> There are several other useful utilities available on his site, such as <a href="https://code.kliu.org/misc/elevate/" rel="external">elevate</a>, <a href="https://code.kliu.org/misc/hidecon/" rel="external">hidecon</a>, <a href="https://code.kliu.org/misc/vcopy/" rel="external">vcopy</a>, <a href="https://code.kliu.org/misc/fontreg/" rel="external">fontreg</a>, the shell extensions </span><a href="https://code.kliu.org/cmdopen/" rel="external">ContextConsole -aka- Open Command Prompt</a>, <span>and <a href="https://code.kliu.org/hashcheck/" rel="external">HashCheck</a>, among others, so look around and have fun! The two shell extensions mentioned are even open source, with source code available for download.</span>
</p>

<p>
	<span>Cheers and Regards</span>
</p>
]]></description><guid isPermaLink="false">180935</guid><pubDate>Thu, 02 Jan 2020 16:50:10 +0000</pubDate></item><item><title>Batch file to delete specific folders</title><link>https://msfn.org/board/topic/181550-batch-file-to-delete-specific-folders/</link><description><![CDATA[<p>
	Greetings
</p>

<p>
	I m trying to create a batch file in a way that - if i run it - it will <strong>delete the content inside specific folders</strong>: Those folders are the below:
</p>

<p>
	 
</p>

<p>
	C:\Windows\Prefetch
</p>

<p>
	C:\Windows\Temp
</p>

<p>
	C:\Users\Haris\AppData\Local\Temp
</p>

<p>
	 
</p>

<p>
	Can anyone help?
</p>

<p>
	 
</p>

<p>
	Thanks
</p>
]]></description><guid isPermaLink="false">181550</guid><pubDate>Tue, 26 May 2020 12:44:14 +0000</pubDate></item><item><title>automatically generates a frame</title><link>https://msfn.org/board/topic/181431-automatically-generates-a-frame/</link><description><![CDATA[<p>
	hi everyone,<br />
	<br />
	on this code which automatically generates a frame with encapsulated labels, I would like to generate a maximum of 4 frames. Until then, it works. The problem is that the variable i (number of frames) is not updated when one of the frames is deleted. The variable r is the one I have to retrieve to update the value i. I tried with return and callback without success.
</p>

<p>
	 
</p>

<pre class="ipsCode prettyprint prettyprinted">
<span class="kwd">try</span><span class="pun">:</span><span class="pln">
	</span><span class="kwd">from</span><span class="pln"> </span><span class="typ">Tkinter</span><span class="pln"> </span><span class="kwd">import</span><span class="pln"> </span><span class="pun">*</span><span class="pln">
</span><span class="kwd">except</span><span class="pun">:</span><span class="pln">
	</span><span class="kwd">from</span><span class="pln"> tkinter </span><span class="kwd">import</span><span class="pln"> </span><span class="pun">*</span><span class="pln">
</span><span class="kwd">from</span><span class="pln"> tkinter </span><span class="kwd">import</span><span class="pln"> messagebox                              </span><span class="com"># Librairie des fenêtres d'alerte</span><span class="pln">

</span><span class="kwd">def</span><span class="pln"> removeLabel</span><span class="pun">(</span><span class="pln">var</span><span class="pun">):</span><span class="pln">
    </span><span class="kwd">global</span><span class="pln"> frames
    </span><span class="kwd">global</span><span class="pln"> i
    z </span><span class="pun">=</span><span class="pln"> </span><span class="pun">-</span><span class="lit">1</span><span class="pln">
    </span><span class="kwd">for</span><span class="pln"> frame </span><span class="kwd">in</span><span class="pln"> frames</span><span class="pun">:</span><span class="pln">
        z </span><span class="pun">=</span><span class="pln"> z </span><span class="pun">+</span><span class="pln"> </span><span class="lit">1</span><span class="pln">
        </span><span class="com"># Check the text variable of the label of this frame</span><span class="pln">
        </span><span class="kwd">if</span><span class="pln"> frame</span><span class="pun">.</span><span class="pln">winfo_children</span><span class="pun">()[</span><span class="lit">4</span><span class="pun">].</span><span class="pln">var </span><span class="pun">==</span><span class="pln"> var</span><span class="pun">:</span><span class="pln">                                                        </span><span class="com"># 4 est le nombre de labels à générer dans une frame</span><span class="pln">
           </span><span class="com"># Supprime frame</span><span class="pln">
           frame</span><span class="pun">.</span><span class="pln">destroy</span><span class="pun">()</span><span class="pln">
           </span><span class="com"># Mise à jour du nombre de frame</span><span class="pln">
           frames </span><span class="pun">=</span><span class="pln"> frames</span><span class="pun">[:</span><span class="pln">z</span><span class="pun">]</span><span class="pln"> </span><span class="pun">+</span><span class="pln"> frames</span><span class="pun">[</span><span class="pln">z</span><span class="pun">+</span><span class="lit">1</span><span class="pun">:]</span><span class="pln">
           z </span><span class="pun">=</span><span class="pln"> </span><span class="pun">-</span><span class="lit">1</span><span class="pln">

    </span><span class="com"># Mise à jour du nombre de frame</span><span class="pln">
    r </span><span class="pun">=</span><span class="pln"> </span><span class="lit">0</span><span class="pln">
    </span><span class="kwd">for</span><span class="pln"> frame </span><span class="kwd">in</span><span class="pln"> frames</span><span class="pun">:</span><span class="pln">
        frame</span><span class="pun">.</span><span class="pln">winfo_children</span><span class="pun">()[</span><span class="lit">4</span><span class="pun">].</span><span class="pln">var</span><span class="pun">.</span><span class="pln">set</span><span class="pun">(</span><span class="pln">r</span><span class="pun">)</span><span class="pln">
        r </span><span class="pun">=</span><span class="pln"> r </span><span class="pun">+</span><span class="pln"> </span><span class="lit">1</span><span class="pln">
    i </span><span class="pun">=</span><span class="pln"> i </span><span class="pun">-</span><span class="pln"> </span><span class="lit">1</span><span class="pln">
    </span><span class="kwd">print</span><span class="pun">(</span><span class="str">"i"</span><span class="pun">,</span><span class="pln"> i</span><span class="pun">)</span><span class="pln">

</span><span class="kwd">def</span><span class="pln"> addNewLabel</span><span class="pun">():</span><span class="pln">
    </span><span class="kwd">global</span><span class="pln">  frames</span><span class="pun">,</span><span class="pln"> i
    </span><span class="kwd">global</span><span class="pln"> table
    var </span><span class="pun">=</span><span class="pln"> </span><span class="typ">IntVar</span><span class="pun">()</span><span class="pln">

    frame </span><span class="pun">=</span><span class="pln"> </span><span class="typ">Frame</span><span class="pun">(</span><span class="pln">root</span><span class="pun">)</span><span class="pln">
    i </span><span class="pun">=</span><span class="pln"> i </span><span class="pun">+</span><span class="pln"> </span><span class="lit">1</span><span class="pln">

    </span><span class="kwd">if</span><span class="pln"> i </span><span class="pun">&lt;=</span><span class="pln"> </span><span class="lit">5</span><span class="pun">:</span><span class="pln">
        frame</span><span class="pun">.</span><span class="pln">grid</span><span class="pun">(</span><span class="pln">row</span><span class="pun">=</span><span class="pln">i</span><span class="pun">,</span><span class="pln"> column</span><span class="pun">=</span><span class="lit">4</span><span class="pun">)</span><span class="pln">
        var</span><span class="pun">.</span><span class="pln">set</span><span class="pun">(</span><span class="pln">len</span><span class="pun">(</span><span class="pln">frames</span><span class="pun">))</span><span class="pln">
        l </span><span class="pun">=</span><span class="pln"> </span><span class="typ">Label</span><span class="pun">(</span><span class="pln">frame</span><span class="pun">,</span><span class="pln"> text</span><span class="pun">=</span><span class="str">"test"</span><span class="pun">)</span><span class="pln">
        l</span><span class="pun">.</span><span class="pln">grid</span><span class="pun">(</span><span class="pln">row</span><span class="pun">=</span><span class="lit">0</span><span class="pun">,</span><span class="pln"> column</span><span class="pun">=</span><span class="lit">0</span><span class="pun">)</span><span class="pln">
        l </span><span class="pun">=</span><span class="pln"> </span><span class="typ">Label</span><span class="pun">(</span><span class="pln">frame</span><span class="pun">,</span><span class="pln"> textvariable</span><span class="pun">=</span><span class="pln">var</span><span class="pun">)</span><span class="pln">
        l</span><span class="pun">.</span><span class="pln">grid</span><span class="pun">(</span><span class="pln">row</span><span class="pun">=</span><span class="lit">0</span><span class="pun">,</span><span class="pln"> column</span><span class="pun">=</span><span class="lit">1</span><span class="pun">)</span><span class="pln">
        l </span><span class="pun">=</span><span class="pln"> </span><span class="typ">Label</span><span class="pun">(</span><span class="pln">frame</span><span class="pun">,</span><span class="pln"> textvariable</span><span class="pun">=</span><span class="pln">var</span><span class="pun">)</span><span class="pln">
        l</span><span class="pun">.</span><span class="pln">grid</span><span class="pun">(</span><span class="pln">row</span><span class="pun">=</span><span class="lit">0</span><span class="pun">,</span><span class="pln"> column</span><span class="pun">=</span><span class="lit">2</span><span class="pun">)</span><span class="pln">
        l </span><span class="pun">=</span><span class="pln"> </span><span class="typ">Label</span><span class="pun">(</span><span class="pln">frame</span><span class="pun">,</span><span class="pln"> textvariable</span><span class="pun">=</span><span class="pln">var</span><span class="pun">)</span><span class="pln">
        l</span><span class="pun">.</span><span class="pln">grid</span><span class="pun">(</span><span class="pln">row</span><span class="pun">=</span><span class="lit">0</span><span class="pun">,</span><span class="pln"> column</span><span class="pun">=</span><span class="lit">3</span><span class="pun">)</span><span class="pln">
        l </span><span class="pun">=</span><span class="pln"> </span><span class="typ">Label</span><span class="pun">(</span><span class="pln">frame</span><span class="pun">,</span><span class="pln"> textvariable</span><span class="pun">=</span><span class="pln">var</span><span class="pun">)</span><span class="pln">
        l</span><span class="pun">.</span><span class="pln">grid</span><span class="pun">(</span><span class="pln">row</span><span class="pun">=</span><span class="lit">0</span><span class="pun">,</span><span class="pln"> column</span><span class="pun">=</span><span class="lit">4</span><span class="pun">)</span><span class="pln">
        l</span><span class="pun">.</span><span class="pln">var </span><span class="pun">=</span><span class="pln"> var

        b </span><span class="pun">=</span><span class="pln"> </span><span class="typ">Button</span><span class="pun">(</span><span class="pln">frame</span><span class="pun">,</span><span class="pln"> text</span><span class="pun">=</span><span class="str">"Remove"</span><span class="pun">,</span><span class="pln"> command</span><span class="pun">=</span><span class="kwd">lambda</span><span class="pun">:</span><span class="pln"> removeLabel</span><span class="pun">(</span><span class="pln">var</span><span class="pun">))</span><span class="pln">
        b</span><span class="pun">.</span><span class="pln">grid</span><span class="pun">(</span><span class="pln">row</span><span class="pun">=</span><span class="lit">0</span><span class="pun">,</span><span class="pln"> column</span><span class="pun">=</span><span class="lit">5</span><span class="pun">)</span><span class="pln">

        frames</span><span class="pun">.</span><span class="pln">append</span><span class="pun">(</span><span class="pln">frame</span><span class="pun">)</span><span class="pln">                                                </span><span class="com"># liste des frames générée</span><span class="pln">

    </span><span class="kwd">print</span><span class="pun">(</span><span class="str">"var.get()  "</span><span class="pun">,</span><span class="pln"> var</span><span class="pun">.</span><span class="pln">get</span><span class="pun">(),</span><span class="pln"> </span><span class="str">"     i  "</span><span class="pun">,</span><span class="pln">i</span><span class="pun">)</span><span class="pln">
    </span><span class="com"># var.trace("w", lambda name, index, mode, i=i: removeLabel(i))</span><span class="pln">
    </span><span class="com"># print("eeeee", i)</span><span class="pln">


    </span><span class="kwd">if</span><span class="pln"> i </span><span class="pun">&gt;</span><span class="pln"> </span><span class="lit">5</span><span class="pun">:</span><span class="pln">                                                                               </span><span class="com"># Limite du nombre de 10 frames à générer</span><span class="pln">
        messagebox</span><span class="pun">.</span><span class="pln">showinfo</span><span class="pun">(</span><span class="str">"Info"</span><span class="pun">,</span><span class="str">"Seulement 10 huiles peuvent être sélectionées"</span><span class="pun">)</span><span class="pln">
        c</span><span class="pun">.</span><span class="pln">configure</span><span class="pun">(</span><span class="pln">state</span><span class="pun">=</span><span class="pln">DISABLED</span><span class="pun">)</span><span class="pln">
        </span><span class="kwd">return</span><span class="pln"> </span><span class="str">"break"</span><span class="pln">
    </span><span class="kwd">print</span><span class="pun">(</span><span class="str">"+i+"</span><span class="pun">,</span><span class="pln">i</span><span class="pun">)</span><span class="pln">


</span><span class="kwd">if</span><span class="pln"> __name__ </span><span class="pun">==</span><span class="pln"> </span><span class="str">'__main__'</span><span class="pun">:</span><span class="pln">
   root </span><span class="pun">=</span><span class="pln"> </span><span class="typ">Tk</span><span class="pun">()</span><span class="pln">
   frames </span><span class="pun">=</span><span class="pln"> </span><span class="pun">[]</span><span class="pln">
   table </span><span class="pun">=</span><span class="pln"> </span><span class="pun">[]</span><span class="pln">
   ind </span><span class="pun">=</span><span class="pln"> </span><span class="pun">[]</span><span class="pln">
   ind1 </span><span class="pun">=</span><span class="pln"> </span><span class="pun">[]</span><span class="pln">
   i </span><span class="pun">=</span><span class="pln"> </span><span class="lit">1</span><span class="pln">

   c </span><span class="pun">=</span><span class="pln"> </span><span class="typ">Button</span><span class="pun">(</span><span class="pln">root</span><span class="pun">,</span><span class="pln"> text</span><span class="pun">=</span><span class="str">"add label"</span><span class="pun">,</span><span class="pln"> command</span><span class="pun">=</span><span class="pln">addNewLabel</span><span class="pun">)</span><span class="pln">
   c</span><span class="pun">.</span><span class="pln">grid</span><span class="pun">(</span><span class="pln">column</span><span class="pun">=</span><span class="lit">0</span><span class="pun">,</span><span class="pln"> row</span><span class="pun">=</span><span class="lit">0</span><span class="pun">)</span><span class="pln">
   root</span><span class="pun">.</span><span class="pln">mainloop</span><span class="pun">()</span></pre>

<p>
	 
</p>
]]></description><guid isPermaLink="false">181431</guid><pubDate>Sun, 19 Apr 2020 09:25:56 +0000</pubDate></item></channel></rss>
