<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Select Folder dialog in 3ds Max Programming Forum</title>
    <link>https://forums.autodesk.com/t5/3ds-max-programming-forum/select-folder-dialog/m-p/8347479#M9538</link>
    <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/5637024"&gt;@chrisdawlud&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;Thank you for response. This&amp;nbsp;example&amp;nbsp; creates the same basic dialog as&amp;nbsp;&lt;EM&gt;getSavePath()&lt;/EM&gt; &lt;SPAN&gt;function and although it does the job I would&amp;nbsp;like to&amp;nbsp;avoid it because tree view is not clear to read.&lt;/SPAN&gt;&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;What do you mean by the same basic dialog, care to share a screenshot? When testing it, I don't see a difference between the dialog in your screenshot and the dialog invoked by this (it used to be different in older max versions but you were talking about Projects toolbar which is fairly recent).&lt;/P&gt;</description>
    <pubDate>Sat, 20 Oct 2018 08:51:06 GMT</pubDate>
    <dc:creator>Swordslayer</dc:creator>
    <dc:date>2018-10-20T08:51:06Z</dc:date>
    <item>
      <title>Select Folder dialog</title>
      <link>https://forums.autodesk.com/t5/3ds-max-programming-forum/select-folder-dialog/m-p/8345900#M9534</link>
      <description>&lt;P&gt;Hey guys. I want to&amp;nbsp;create 'select folder' dialog window in maxscript looking just&amp;nbsp;like this one below. It is from the new &lt;SPAN&gt;3ds max 2019&amp;nbsp;&lt;/SPAN&gt;'Projects' toolbar so I assume the right&amp;nbsp;objects&amp;nbsp;and methods are somewhere available to the user. I already tried&amp;nbsp; .NET's&amp;nbsp;&lt;EM&gt;OpenFileDialog&lt;/EM&gt; and &lt;EM&gt;FolderBrowserDialog&lt;/EM&gt;&amp;nbsp;but they lack functionality.&lt;/P&gt;&lt;P&gt;I thought I could &lt;SPAN&gt;maybe&amp;nbsp;&lt;/SPAN&gt;somehow&amp;nbsp;take a look into&amp;nbsp;'Projects' toolbar's macroscript source code like I can with some&amp;nbsp; 3rd party&amp;nbsp;toolbars but it seems&amp;nbsp;it's hidden for a reason?&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="123.jpg" style="width: 567px;"&gt;&lt;img src="https://forums.autodesk.com/t5/image/serverpage/image-id/559463iCF908D47647892C5/image-dimensions/567x311?v=v2" width="567" height="311" role="button" title="123.jpg" alt="123.jpg" /&gt;&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 19 Oct 2018 13:56:28 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/3ds-max-programming-forum/select-folder-dialog/m-p/8345900#M9534</guid>
      <dc:creator>chrisdawlud</dc:creator>
      <dc:date>2018-10-19T13:56:28Z</dc:date>
    </item>
    <item>
      <title>Re: Select Folder dialog</title>
      <link>https://forums.autodesk.com/t5/3ds-max-programming-forum/select-folder-dialog/m-p/8346072#M9535</link>
      <description>&lt;P&gt;You can find the functionality under stdscripts but the toolbar is not a regular toolbar (no macro buttons etc). You would want to use SDK methods instead. For example:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;(
	local compilerParams = dotNetObject "System.CodeDom.Compiler.CompilerParameters" #(
		getDir #maxRoot + "Autodesk.Max.dll",
		getDir #maxRoot + "ManagedServices.dll")
	compilerParams.GenerateInMemory = on

	local compilerResults = (dotNetObject "Microsoft.CSharp.CSharpCodeProvider").CompileAssemblyFromSource compilerParams #(
		"using System;
		using Autodesk.Max;
		using SDK = ManagedServices.AppSDK;

		public class Dialogs {
			private static readonly IGlobal Global = Autodesk.Max.GlobalInterface.Instance;

			public static string BrowseForFolder(string title) {
				string folder = string.Empty;
				Global.COREInterface9.DoMaxBrowseForFolder(SDK.GetMaxHWND(), title, ref folder);

				return folder;
			}
		}"
	)
	::Dialogs = compilerResults.CompiledAssembly.CreateInstance "Dialogs"
)
&lt;/PRE&gt;
&lt;P&gt;And now you can call:&lt;/P&gt;
&lt;PRE&gt;Dialogs.BrowseForFolder "Here comes the title"&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 19 Oct 2018 14:49:01 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/3ds-max-programming-forum/select-folder-dialog/m-p/8346072#M9535</guid>
      <dc:creator>Swordslayer</dc:creator>
      <dc:date>2018-10-19T14:49:01Z</dc:date>
    </item>
    <item>
      <title>Re: Select Folder dialog</title>
      <link>https://forums.autodesk.com/t5/3ds-max-programming-forum/select-folder-dialog/m-p/8346078#M9536</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/5637024"&gt;@chrisdawlud&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;would :&lt;/P&gt;
&lt;P&gt;getSavePath()&lt;/P&gt;
&lt;P&gt;be good for you ?&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 19 Oct 2018 14:49:48 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/3ds-max-programming-forum/select-folder-dialog/m-p/8346078#M9536</guid>
      <dc:creator>ads_royje</dc:creator>
      <dc:date>2018-10-19T14:49:48Z</dc:date>
    </item>
    <item>
      <title>Re: Select Folder dialog</title>
      <link>https://forums.autodesk.com/t5/3ds-max-programming-forum/select-folder-dialog/m-p/8347470#M9537</link>
      <description>&lt;P&gt;Thank you for response. This&amp;nbsp;example&amp;nbsp; creates the same basic dialog as&amp;nbsp;&lt;EM&gt;getSavePath()&lt;/EM&gt; &lt;SPAN&gt;function and although it does the job I would&amp;nbsp;like to&amp;nbsp;avoid it because tree view is not clear to read.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;I found &lt;A href="https://stackoverflow.com/a/41511598/9114655" target="_blank"&gt;one way of doing this&lt;/A&gt;,&amp;nbsp;but I have to include&amp;nbsp;nuget package. At this point should I&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;dive into Visual Studio or is it still possible to achieve only in maxscript using SDK methods?&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Sat, 20 Oct 2018 08:42:46 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/3ds-max-programming-forum/select-folder-dialog/m-p/8347470#M9537</guid>
      <dc:creator>chrisdawlud</dc:creator>
      <dc:date>2018-10-20T08:42:46Z</dc:date>
    </item>
    <item>
      <title>Re: Select Folder dialog</title>
      <link>https://forums.autodesk.com/t5/3ds-max-programming-forum/select-folder-dialog/m-p/8347479#M9538</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/5637024"&gt;@chrisdawlud&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;Thank you for response. This&amp;nbsp;example&amp;nbsp; creates the same basic dialog as&amp;nbsp;&lt;EM&gt;getSavePath()&lt;/EM&gt; &lt;SPAN&gt;function and although it does the job I would&amp;nbsp;like to&amp;nbsp;avoid it because tree view is not clear to read.&lt;/SPAN&gt;&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;What do you mean by the same basic dialog, care to share a screenshot? When testing it, I don't see a difference between the dialog in your screenshot and the dialog invoked by this (it used to be different in older max versions but you were talking about Projects toolbar which is fairly recent).&lt;/P&gt;</description>
      <pubDate>Sat, 20 Oct 2018 08:51:06 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/3ds-max-programming-forum/select-folder-dialog/m-p/8347479#M9538</guid>
      <dc:creator>Swordslayer</dc:creator>
      <dc:date>2018-10-20T08:51:06Z</dc:date>
    </item>
    <item>
      <title>Re: Select Folder dialog</title>
      <link>https://forums.autodesk.com/t5/3ds-max-programming-forum/select-folder-dialog/m-p/8347532#M9539</link>
      <description>&lt;P&gt;Sorry, my bad. It's working&amp;nbsp;perfectly with max 2019. I tested it in 2018 version, hence my confusion. Thanks very much&lt;/P&gt;</description>
      <pubDate>Sat, 20 Oct 2018 10:14:15 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/3ds-max-programming-forum/select-folder-dialog/m-p/8347532#M9539</guid>
      <dc:creator>chrisdawlud</dc:creator>
      <dc:date>2018-10-20T10:14:15Z</dc:date>
    </item>
  </channel>
</rss>

