DigitalPlatform / blog

技术文章
0 stars 0 forks source link

零星技术问题 #27

Open DigitalPlatform opened 5 years ago

DigitalPlatform commented 5 years ago

https://stackoverflow.com/questions/24774236/c-sharp-mdi-winforms-child-activation

https://stackoverflow.com/questions/19382705/c-sharp-volatile-keyword-usage-vs-lock

这里实现了一个专门的 AtomicBoolean 类来处理并发环境下的 bool 变量修改问题 https://stackoverflow.com/questions/6661055/using-interlocked-compareexchange-operation-on-a-bool-value

讨论了 volatile 变量的各种 https://stackoverflow.com/questions/154551/volatile-vs-interlocked-vs-lock

https://stackoverflow.com/questions/10556806/make-a-linked-list-thread-safe

DigitalPlatform commented 5 years ago

https://www.c-sharpcorner.com/UploadFile/7ca517/unit-test-with-console-application/

DigitalPlatform commented 5 years ago

何时用 Task.Delay() 何时用 Thread.Sleep()? https://stackoverflow.com/questions/20082221/when-to-use-task-delay-when-to-use-thread-sleep

DigitalPlatform commented 5 years ago

语音技术

http://ibillxia.github.io/blog/2012/11/24/several-plantforms-on-audio-and-speech-signal-processing/

https://doc.xfyun.cn/msc_windows/

https://www.admin5.com/article/20170420/738250.shtml

https://www.leiphone.com/news/201610/BSlh3Kf6wcqNCRH9.html

https://github.com/nl8590687/ASRT_SpeechRecognition

DigitalPlatform commented 5 years ago

https://stackoverflow.com/questions/15868817/button-inside-a-winforms-textbox

DigitalPlatform commented 5 years ago

https://stackoverflow.com/questions/735822/working-with-singletons-in-net-remoting

https://www.codeproject.com/articles/62813/net-remoting-events-explained

DigitalPlatform commented 5 years ago

USB

https://www.developerfusion.com/article/84338/making-usb-c-friendly/

https://stackoverflow.com/questions/3331043/get-list-of-connected-usb-devices

DigitalPlatform commented 5 years ago

AssemblyVersion 中的版本号问题 https://www.cnblogs.com/mq0036/p/9429708.html

DigitalPlatform commented 5 years ago

https://stackoverflow.com/questions/8138130/default-path-of-dll-in-dllimportxyzdll

https://stackoverflow.com/questions/8836093/how-can-i-specify-a-dllimport-path-at-runtime

DigitalPlatform commented 5 years ago

OCR

https://blogs.windows.com/buildingapps/2016/02/08/optical-character-recognition-ocr-for-windows-10/#kcyVr9Z1FBO1jTfy.97

https://docs.microsoft.com/en-us/uwp/api/Windows.Media.Ocr

https://stackoverflow.com/questions/52537944/is-using-windows-media-ocr-only-support-for-uwp-app

http://www.lostindetails.com/blog/post/Using-Windows-Built-in-OCR-from-CSharp

DigitalPlatform commented 5 years ago

https://www.cnblogs.com/s5689412/p/9825010.html 如何解决“请考虑使用 app.config 将程序集“XXXXXXXX”从版本XXXX重新映射到版本XXXX”的问题

DigitalPlatform commented 5 years ago

https://stackoverflow.com/questions/5053172/why-does-the-lock-object-have-to-be-static

DigitalPlatform commented 5 years ago

ClickOnce

https://stackoverflow.com/questions/605954/recommendations-for-clearing-out-clickonce-deployment-junk

https://stackoverflow.com/questions/2418542/clear-the-net-downloaded-application-cache-without-mage

https://docs.microsoft.com/en-us/visualstudio/deployment/clickonce-cache-overview?view=vs-2019

https://dev.to/chriscooper01/user-roaming-profile-clickonce-application-restore-2io1

https://textslashplain.com/2019/01/02/demystifying-clickonce/

https://docs.microsoft.com/en-us/visualstudio/msbuild/generateapplicationmanifest-task?view=vs-2019

https://docs.microsoft.com/en-us/visualstudio/deployment/building-clickonce-applications-from-the-command-line?view=vs-2019

DigitalPlatform commented 5 years ago

依赖注入

https://www.zhihu.com/question/27181326

https://blog.csdn.net/qq_18995513/article/details/53410384

https://www.cnblogs.com/icoolno1/p/6941702.html

https://msdn.microsoft.com/zh-cn/magazine/mt707534.aspx

autofac

https://autofac.readthedocs.io/en/latest/getting-started/index.html

DigitalPlatform commented 5 years ago

MS SQL Server

https://social.msdn.microsoft.com/forums/sqlserver/en-US/cb42262c-abfa-40f5-86b5-62e8132f2559/alter-database-to-set-smaller-filegrowth

https://docs.microsoft.com/en-us/sql/t-sql/statements/create-database-transact-sql?view=sql-server-2017

<filespec> ::=
{
(
    NAME = logical_file_name ,
    FILENAME = { 'os_file_name' | 'filestream_path' }
    [ , SIZE = size [ KB | MB | GB | TB ] ]
    [ , MAXSIZE = { max_size [ KB | MB | GB | TB ] | UNLIMITED } ]
    [ , FILEGROWTH = growth_increment [ KB | MB | GB | TB | % ] ]
)
}

https://stackoverflow.com/questions/8837207/create-database-using-script-at-the-default-path

https://stackoverflow.com/questions/38590066/log-file-is-growing-with-simple-recovery-mode

https://support.microsoft.com/zh-cn/help/315512/considerations-for-the-autogrow-and-autoshrink-settings-in-sql-server

https://stackoverflow.com/questions/1195867/huge-transaction-log-with-sql-server-database-in-simple-recovery-mode

https://blogs.msdn.microsoft.com/sqlserverstorageengine/2007/03/28/turn-auto_shrink-off/

DigitalPlatform commented 5 years ago

https://weblogs.asp.net/thomaslebrun/windows-seven-how-to-use-biometric-authentication-in-your-net-applications

DigitalPlatform commented 5 years ago

https://stackoverflow.com/questions/3213606/how-to-suppress-task-switch-keys-winkey-alt-tab-alt-esc-ctrl-esc-using-low

DigitalPlatform commented 5 years ago

https://stackoverflow.com/questions/9992223/file-getlastwritetime-seems-to-be-returning-out-of-date-value GetLastWriteTime 并不确保返回最新的最后修改时间

DigitalPlatform commented 4 years ago

顶层窗口,但没有焦点

https://social.msdn.microsoft.com/forums/en-US/b7df1480-2f6e-443f-abf5-c9bf4736c5d8/window-with-topmost-without-focus Window with topmost without focus

https://stackoverflow.com/questions/683330/how-to-make-a-window-always-stay-on-top-in-net

https://stackoverflow.com/questions/257587/bring-a-window-to-the-front-in-wpf

https://stackoverflow.com/questions/3729899/opening-a-winforms-form-with-topmost-true-but-not-having-it-steal-focus

https://www.codeproject.com/Articles/38507/Using-the-WPF-FocusScope

https://stackoverflow.com/questions/45953424/wpf-virtual-keyboard-dialog-steals-textbox-keyboard-focus

https://www.cnblogs.com/yfceshi/p/6791943.html

https://blogs.msdn.microsoft.com/toub/2006/05/03/low-level-mouse-hook-in-c/

https://stackoverflow.com/questions/11572411/sendkeys-send-method-in-wpf-application

DigitalPlatform commented 4 years ago

WPF 坐标和屏幕坐标转换

https://stackoverflow.com/questions/6931333/wpf-converting-between-screen-coordinates-and-wpf-coordinates

https://stackoverflow.com/questions/18103540/wpf-client-to-screen-point-transformation

https://docs.microsoft.com/en-us/dotnet/framework/wpf/graphics-multimedia/hit-testing-in-the-visual-layer

http://csharphelper.com/blog/2014/10/perform-hit-testing-in-a-3d-program-that-uses-wpf-xaml-and-c/

https://engy.us/blog/2010/03/08/saving-window-size-and-location-in-wpf-and-winforms/

https://stackoverflow.com/questions/7417739/make-wpf-window-draggable-no-matter-what-element-is-clicked

https://stackoverflow.com/questions/1190423/using-setwindowpos-in-c-sharp-to-move-windows-around

https://stackoverflow.com/questions/9003212/how-to-change-size-of-wpf-window-dynamically

https://stackoverflow.com/questions/7620488/how-to-set-the-location-of-wpf-window-to-the-bottom-right-corner-of-desktop

DigitalPlatform commented 4 years ago

鼠标钩子

https://www.cnblogs.com/yfceshi/p/6791943.html

https://docs.microsoft.com/en-us/archive/blogs/toub/low-level-mouse-hook-in-c

https://stackoverflow.com/questions/2063974/how-do-i-capture-the-mouse-move-event

https://stackoverflow.com/questions/34217231/how-to-programmatically-disable-edge-swipe-gesture-of-the-windows-10-tablet-scre

DigitalPlatform commented 4 years ago

https://devblogs.microsoft.com/premier-developer/taskschedulers-and-semaphores/ TaskSchedulers and semaphores 如何让 TaskScheduler 同一个时刻只允许一个 Task 运行

https://docs.microsoft.com/en-us/dotnet/standard/parallel-programming/how-to-specify-a-task-scheduler-in-a-dataflow-block?view=netframework-4.8 例子程序

https://docs.microsoft.com/en-us/dotnet/api/system.threading.tasks.concurrentexclusiveschedulerpair?redirectedfrom=MSDN&view=netframework-4.8

https://stackoverflow.com/questions/20084695/c-sharp-lock-and-async-method

DigitalPlatform commented 4 years ago

FileInfo 信息陈旧问题

https://docs.microsoft.com/en-us/dotnet/api/system.io.filesysteminfo.refresh?view=netframework-4.8

DigitalPlatform commented 4 years ago

IIS 管理 AppCmd

https://docs.microsoft.com/zh-cn/archive/blogs/mikezh/iis-appcmd-quick-reference

DigitalPlatform commented 4 years ago

UI & Deadlock

https://devblogs.microsoft.com/pfxteam/await-and-ui-and-deadlocks-oh-my/

https://stackoverflow.com/questions/5401549/ways-to-improve-wpf-ui-rendering-speed

https://stackoverflow.com/questions/58237847/how-to-resolve-vs2019-warning-to-use-joinabletaskfactory-switchtomainthreadasyn

https://devblogs.microsoft.com/premier-developer/asynchronous-and-multithreaded-programming-within-vs-using-the-joinabletaskfactory/

https://github.com/Microsoft/vs-threading/blob/master/doc/cookbook_vs.md

https://github.com/microsoft/vs-threading/issues/447#issuecomment-481481389

DigitalPlatform commented 4 years ago

字符集

https://www.qqxiuzi.cn/bianma/zifuji.php

https://www.cnblogs.com/sosoft/p/3456631.html Unicode中文和特殊字符的编码范围

DigitalPlatform commented 4 years ago

Dead Lock

https://michaelscodingspot.com/c-deadlocks-in-depth-part-1/ https://michaelscodingspot.com/c-deadlocks-in-depth-part-2/ https://michaelscodingspot.com/how-to-debug-net-deadlocks-c-deadlocks-in-depth-part-3/

https://stackoverflow.com/questions/15021304/an-async-await-example-that-causes-a-deadlock

https://devblogs.microsoft.com/pfxteam/are-deadlocks-still-possible-with-await/

https://olitee.com/2015/01/c-async-await-common-deadlock-scenario/

DigitalPlatform commented 4 years ago

通讯手段选择

https://michaelscodingspot.com/rest-vs-grpc-for-asp-net/

DigitalPlatform commented 4 years ago

https://stackoverflow.com/questions/3299021/net-listview-refresh

DigitalPlatform commented 4 years ago

串口通讯

https://github.com/meetanthony/crccsharp

https://github.com/IvoBrandao/CRCMaster/blob/master/CRC%20Master/CRCMaster.cs

https://github.com/Gaofei244617/CRC/blob/master/CRC/CRC.cs

https://blog.csdn.net/tx_yu/article/details/4789067 CRC 校验算法

https://blog.csdn.net/xundh/article/details/42417829 串口监听工具

https://blog.csdn.net/u012842630/article/details/85346397 串口监听工具

https://www.virtual-serial-port.org/articles/best-serial-port-monitor-utilities/

https://github.com/whitestone-no/open-serial-port-monitor

DigitalPlatform commented 4 years ago

Unicode

https://dencode.com/en/string

https://docs.microsoft.com/en-us/dotnet/api/system.string.normalize?view=netcore-3.1

https://docs.microsoft.com/en-us/windows/win32/intl/nls--unicode-normalization-sample

https://csharpindepth.com/articles/Unicode

https://gingter.org/2018/07/10/how-to-correctly-normalize-strings-and-how-to-compare-them-in-net/

https://stackoverflow.com/questions/9349608/how-to-check-if-unicode-character-has-diacritics-in-net

https://code-examples.net/en/q/57d93

DigitalPlatform commented 4 years ago

Windows Logon

https://stackoverflow.com/questions/1448372/how-to-detect-windows-logon-event

https://stackoverflow.com/questions/5298823/how-to-identify-logon-event-in-window-service

https://stackoverflow.com/questions/6799955/how-to-detect-windows-shutdown-or-logoff

https://www.codeproject.com/tips/508779/simple-windows-service-to-find-system-turn-on-turn CanHandleSessionChange

https://forums.asp.net/t/1178230.aspx?C+determine+which+user+a+windows+service+is+running+as

https://stackoverflow.com/questions/40423190/detect-windows-logon-attempts-programmatically-using-c-sharp

===

https://stackoverflow.com/questions/5089601/how-to-run-a-c-sharp-application-at-windows-startup

=== https://stackoverflow.com/questions/31793088/c-sharp-run-wpf-application-from-windows-service

DigitalPlatform commented 4 years ago

临时保存

https://stackoverflow.com/questions/17908993/starting-a-process-with-a-user-name-and-password

https://stackoverflow.com/questions/3147911/wait-until-a-process-ends

https://docs.microsoft.com/zh-cn/dotnet/api/system.io.compression.zipfile.extracttodirectory?view=netcore-3.1#System_IO_Compression_ZipFile_ExtractToDirectory_System_String_System_String_System_Text_Encoding_

https://stackoverflow.com/questions/234231/creating-application-shortcut-in-a-directory

https://stackoverflow.com/questions/4897655/create-a-shortcut-on-desktop/14632782#14632782

https://www.howtogeek.com/190897/how-can-you-open-and-edit-windows-.lnk-shortcut-files/

https://stackoverflow.com/questions/39300787/dynamic-reference-in-a-net-core-app-targeting-net-standard-1-6

https://github.com/serilog/serilog/wiki/Getting-Started

https://github.com/serilog/serilog

DigitalPlatform commented 4 years ago

Serilog

https://stackify.com/serilog-tutorial-net-logging/

https://stackoverflow.com/questions/21489114/topshelf-nlog-and-file-permissions

DigitalPlatform commented 4 years ago

msix core

https://stackoverflow.com/questions/57955302/installer-for-net-core-3-wpf-winforms-non-msix

DigitalPlatform commented 4 years ago

MS SQL Server

https://dba.stackexchange.com/questions/58137/db-owner-unable-to-drop-database-error-615-sql-server

DigitalPlatform commented 4 years ago

Windows 家庭版添加组策略管理界面

https://zhuanlan.zhihu.com/p/122470717

DigitalPlatform commented 4 years ago

https://www.tenforums.com/tutorials/48507-enable-disable-edge-swipe-screen-windows-10-a.html

Edge UI

Open the Local Group Policy Editor.

2 In the left pane of Local Group Policy Editor, navigate to the location below. (see screenshot below)

Computer Configuration/Administrative Templates/Windows Components/Edge UI


HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\EdgeUI

AllowEdgeSwipe DWORD

(delete) = Enable 0 = Disable

DigitalPlatform commented 4 years ago

UAC

https://blog.csdn.net/Linux7985/article/details/50525381

https://www.yanning.wang/archives/172.html

https://stackoverflow.com/questions/33285468/display-a-uac-shield-icon-next-to-a-wpf-button

DigitalPlatform commented 4 years ago

WebRequest 的缓存问题

https://blog.sverrirs.com/2016/04/webrequest-caching-in-csharp.html

DigitalPlatform commented 3 years ago

Sound frequency

https://stackoverflow.com/questions/14042630/how-to-generate-sounds-according-to-frequency

http://soundbible.com/free-sound-effects-1.html

https://docs.microsoft.com/en-us/dotnet/api/system.speech.synthesis.promptbuilder.appendaudio?view=netframework-4.8#System_Speech_Synthesis_PromptBuilder_AppendAudio_System_String_

https://www.codeguru.com/columns/dotnet/making-sounds-with-waves-using-c.html

https://github.com/naudio/NAudio

DigitalPlatform commented 3 years ago

Windows 任务计划

https://www.cnblogs.com/tonge/p/4410066.html

https://stackoverflow.com/questions/7394806/creating-scheduled-tasks

https://github.com/dahall/taskscheduler

https://github.com/quartznet/quartznet

DigitalPlatform commented 3 years ago

MarkDown 文档编写

https://segmentfault.com/a/1190000012272060 Word强大插件Writage使用手册

https://blog.csdn.net/horses/article/details/108536784 Pandoc:一个超级强大的文档格式转换工具

https://www.jianshu.com/p/4721ddd27027 实用帖 | 如何为 Markdown 文件自动生成目录?

https://zhuanlan.zhihu.com/p/43155010

https://www.zhihu.com/question/20849824

https://www.jianshu.com/p/cf1465772027

https://stackoverflow.com/questions/16383237/how-can-doc-docx-files-be-converted-to-markdown-or-structured-text

To save the images, add the option --extract-media=./ to the command above. It will create a folder media with all the images and they will be correctly shown in the markdown file

pandoc -f docx -t markdown danji.docx -o danji.markdown --extract-media=./
DigitalPlatform commented 3 years ago

StackTrace

https://github.com/aelij/AsyncFriendlyStackTrace

https://stackoverflow.com/questions/3791696/how-to-get-line-numbers-in-the-stacktrace-of-an-exception-thrown-in-net-to-sh

https://stackoverflow.com/questions/15704711/how-can-i-use-control-invoke-to-throw-an-exception-that-wont-be-ignored

https://stackoverflow.com/questions/531695/how-to-print-the-current-stack-trace-in-net-without-any-exception

DigitalPlatform commented 3 years ago

RFC3161 sign url

http://timestamp.comodoca.com/rfc3161 http://timestamp.digicert.com

DigitalPlatform commented 3 years ago

windows-power-events

https://devblogs.microsoft.com/scripting/monitor-and-respond-to-windows-power-events-with-powershell/

DigitalPlatform commented 3 years ago

.zip 文件中的时间格式问题

https://documentation.help/DotNetZip/febb9391-ee1c-1fe3-01ec-cf721e9ca809.htm

DigitalPlatform commented 3 years ago

另一个 .zip 开源项目

https://github.com/jaime-olivares/zipstorer

DigitalPlatform commented 3 years ago

WCF 结合 CookiesContainer 的问题

https://winterdom.com/2015/08/03/wcf-be-careful-with-allowcookiestrue

DigitalPlatform commented 3 years ago

数字签名证书

https://blog.csdn.net/qinyuanpei/article/details/62236843

DigitalPlatform commented 3 years ago

向量相似度搜索

https://github.com/spotify/annoy

https://github.com/milvus-io/milvus

https://github.com/facebookresearch/faiss