Hello, Thanks for your feedback. The use24HourClock only applies to the text value displayed in the spinner control. The graphical clock only supports displaying [1-12] AM/PM for the hours.
This is fantastic. Thanks. Does there exists a .NET 6 version of this? Testing in .NET 6 has not been done. Are there any issues when compiling in .NET 6?
Sample code: TimePicker timePicker = new TimePicker(0, false, true); var tokens = timePicker.Tokens; tokens.Clear(); timePicker.Mask = "99:99\\ LL"; timePicker.DateTimeFormat = "hh:mm tt"; timePicker.Value = timePicker.TextToValue(timePicker.ValueToText(DateTime.Now)); tokens[0].MinValue = 1; tokens[0].MaxValue = 13; tokens[2].MaxValue = 60; tokens[tokens.Count - 1].CustomValues = new Object[] { "AM", "PM" };
There is some inconsistency there. The kernel32.dll FindFirstFileEx method doesn't support multiple filters, so the pipe separated filters was only added to GetFiles but not to EnumerateFiles. The issue with multiple filters is the possibility that the same file is hit by multiple filters. E.g. if there is a file called data.txt and two filters are specified data.*|*.txt then the EnumerateFiles would return data.txt twice. However, the GetFiles(...) method checks for duplicates. EnumerateFiles should...
GetFiles(String path, String searchPattern = "*", ...); /// <param name="searchPattern">The search string to match against files in the path. Multiple can be specified separated by the pipe character.
A new version has been released with the option to specify an IFolderFilter object. For example, to skip over hidden folders: public class SkipHiddenFolders : IFolderFilter { public bool SearchFolder(FastFileInfo folder) { return !folder.Attributes.HasFlag(FileAttributes.Hidden); } } IList<FastFileInfo> list = FastFileInfo.GetFiles("C:\\temp\\", "*", SearchOption.AllDirectories, new SkipHiddenFolders()); For your purpose, change FileAttributes.Hidden to FileAttributes.ReparsePoint.
The Windows FindFirstFileEx method only allows to specify a single filter at a time, and does not have the option to exclude patterns. However, a filter to exclude folders by names could be applied inside the folder enumeration in FastFileInfo. It seems unlikely that excluding .vhdx files specifically would work. I recommend looking at the Attributes of the C:\ProgramData\Microsoft\Windows\Containers\BaseImages folders and see if there's an attribute that could be used to identify the folder as an...
It's probably due to hidden files or folders. The f.Attributes will have the Hidden flag set if a file is hidden. However, there is currently no option in FastFileInfo to exclude hidden folders. That would require an enhancement. Alternatively, new Directory(f.DirectoryName).Attributes could be used to determine if a file's immediate parent folder is hidden, and that check would have to be performed for each folder up to the root folder.
Output both sets to separate text files and compare the text files.
To clear the file system cache I used: https://docs.microsoft.com/en-us/sysinternals/downloads/rammap From the menubar: Empty > Empty Standby List TotalLength ts1 ts2 NumFiles Test #2: 30104229635 131.5281854 0.0156138 154344 Test #3: 30104229635 148.1681834 0.0156301 154344 commenting out everything except assigning Length (no improvement): Test #4: 30104229635 152.9615534 0 154344 The FINDEX_INFO_LEVELS parameter passed into the FindFirstFileEx(...) method doesn't have an option to only query the...
To clear the file system cache I used: https://docs.microsoft.com/en-us/sysinternals/downloads/rammap From the menubar: Empty > Empty Standby List `TotalLength ts1 ts2 NumFiles Test #2: 30104229635 131.5281854 0.0156138 154344 Test #3: 30104229635 148.1681834 0.0156301 154344 commenting out everything except assigning Length (no improvement): Test #4: 30104229635 152.9615534 0 154344 ` The FINDEX_INFO_LEVELS parameter passed into the FindFirstFileEx(...) method doesn't have an option to only query...
Something in your testing is not correct. Summing up the total length takes a fraction of a second. E.g: DateTime now = DateTime.UtcNow; IList<FastFileInfo> list = FastFileInfo.GetFiles(@"C:\Windows", "*.*", SearchOption.AllDirectories); double ts1 = (DateTime.UtcNow - now).TotalSeconds; now = DateTime.UtcNow; long totalLength = 0; for (int i = list.Count - 1; i >= 0; i--) { totalLength += list[i].Length; } double ts2 = (DateTime.UtcNow - now).TotalSeconds; System.Diagnostics.Debug.WriteLine(totalLength...
In the internal FastFileInfo constructor, you could try commenting out everything except for the this.Length = ...; line, and see how the speed compares. In addition to that, you could also try eliminating creating new FastFileInfo objects, and just maintain a long TotalLength value. Other than that, you could search the WinAPI to see if there's a DLL call that only gets the Length and none of the other file properties, but I'm not sure one exists. If you do some performance testing, please post...
Yes, the information is contained in the findData variable. In the MoveNext() method, look at the code: if (hasCurrent || !advanceNext) { // first skip over any directories, but store them if usePendingFolders is true while (((FileAttributes) findData.dwFileAttributes & FileAttributes.Directory) == FileAttributes.Directory) { if (usePendingFolders) { String c = findData.cFileName; if (!(c[0] == '.' && (c.Length == 1 || c[1] == '.' && c.Length == 2))) // skip folders '.' and '..' pendingFolders.Add(Path.Combine(currentFolder,...
Rather than an additional call to System.IO, have you considered extracting the folders using the filenames? However, only folders that contain a matching file are returned, which also means empty folders are not listed either. Does this solve your problem? Sample code: String path = "c:\\temp\\"; String pattern = "*.txt"; SearchOption so = SearchOption.AllDirectories; IList<FastFileInfo> files = FastFileInfo.GetFiles(path, pattern, so); Hashtable htFolders = new Hashtable(); List<String> folders...
Looking at the source code for Directory.GetDirectories, it is calling the same method Win32Native.FindFirstFile(searchPath, ref data); in the internal class FileSystemEnumerableIterator. It is unlikely there is significant performance that can be gained. Have you timed the duration of Directory.GetDirectories in your own project? It makes sense to first confirm that this is actually a bottleneck in your code.
Sample code
Can't build demo program
It might be an issue with different Visual Studio versions. Just start a new Windows Forms project, and then add all the .cs files to it. For v2019, adding a reference to "PresentationCore" is required. Good luck.
A new file (Accordion v2015.08.18b.zip) is available to download. It should be easy now, just open and run.
Make sure you are adding the Accordion object to the form, (e.g. form.Controls .Add(accordion);) and make sure the accordion DockStyle is set to fill (accordion.Dock = DockStyle.Fill;).
Can you confirm your username has permission to create files in the "C:\Opulos Inc\Nu Help\temp\" folder?
In the Settings/Options, there is a checkbox that specifies to Delete Temporary Files on the first tab in the General Options section. Try unchecking that checkbox and see if the hhp file is being created in the temp folder. The file is automatically deleted at the end if unless the option is unchecked.
Did you install htmlhelp.exe from the download zip file?
Does the "Quick Guide.hhp" file exist in the specified folder? If you directly double-click the file, will it open?
Your needs are understood. A new version will be released by next Friday that does a better job of resolving the href links. A message will be posted here when it is released.
The correct way to define a hyperlink to an external file is to edit the hyperlink in Word, and change the hyperlink from "test.txt" to "\\test.txt". This causes MS-Word to ouput href="file:///\\test.txt" rather than href="..\..\..\..\..\..\test.txt". Then make sure that test.txt is in the same folder as the .chm file. However, a new version will be released that detects this case, and alerts the user. Also, an option to copy external files to the output folder (or to a user-specified subfolder relative...
The correct way to define a hyperlink to an external file is to edit the hyperlink in Word, and change the hyperlink from "test.txt" to "\\test.txt". This causes MS-Word to ouput href="file:///\\test.txt" rather than href="..\....\..\..\..\test.txt". Then make sure that test.txt is in the same folder as the .chm file. However, a new version will be released that detects this case, and alerts the user. Also, an option to copy external files to the output folder (or to a user-specified subfolder relative...
The correct way to define a hyperlink to an external file is to edit the hyperlink in Word, and change the hyperlink from "test.txt" to "\test.txt". This causes MS-Word to ouput href="file:///\test.txt" rather than href="............\test.txt". Then make sure that test.txt is in the same folder as the .chm file. However, a new version will be released that detects this case, and alerts the user. Also, an option to copy external files to the output folder (or to a user-specified subfolder relative...
Thanks for the sample file. Hopefully today a test will be done using the file, and a result of the findings will be posted here.
If possible, email the complete word html file to info at opulos.com. In the mean time, an attempt will be made to reproduce the problm based on html snippet you provided.
License of the program
The license is specified as BSD License, which appears near the middle of the summary page, just below the Project Activity section. The source code is in the Files > Source Code folder. The most recently released source code is for version v2016.02.14.
The license is specified as BSD License, which appears near the bottom of the summary page. The source code is in the Files > Source Code folder. The most recently released source code is for version v2016.02.14.
Hi Code Artist. The code is under the BSD license. The summary page has been updated....
It would help to have a code example. If possible, please attach a .cs file or provide...
All source (.cs) files are included in the zip file. In your VS 2008 solution, create...
Download fails to compile
Closing ticket.
All source .cs files are in the "src" folder in the zip file. In solution explorer,...
Closed-Fixed.
Issues on Nesting Accordion
Please try the version just released, v2015.08.03. It should solve your problem....
I thought I was close to a solution calculating the true available width by subtracting...
A solution is almost ready.
It looks like you want to use 'accordion.FillWidth = false'. Let me know if that...
Possibly one of your controls is missing AutoSizeMode = AutoSizeMode.GrowAndShrink....
Hi Rajesh, Possibly one of your controls is missing AutoSizeMode = AutoSizeMode.GrowAndShrink....
Let us know if you would like to help translate NüHelp to a different language. If...