From a7fce532de220a0a2d5975273e5f460dab2183dd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E4=BC=98=E9=9B=85=E7=9A=84=E6=AF=8D=E9=B8=A1?= <710521324@qq.com> Date: Sat, 11 Mar 2023 00:14:42 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E5=8F=82=E6=95=B0=E9=94=99?= =?UTF-8?q?=E8=AF=AF=E6=83=85=E5=86=B5=E7=9A=84=E5=B4=A9=E6=BA=83?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- 淘宝网址解析/Form1.cs | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/淘宝网址解析/Form1.cs b/淘宝网址解析/Form1.cs index 56512cc..5e8501b 100644 --- a/淘宝网址解析/Form1.cs +++ b/淘宝网址解析/Form1.cs @@ -73,7 +73,16 @@ namespace 淘宝网址解析 foreach (var item in 参数) { var 参数与内容 = item.Split("="); - 参数列表.Add(new 网址参数 { 参数名称 = 参数与内容[0], 参数内容 = 参数与内容[1] }); + try + { + 参数列表.Add(new 网址参数 { 参数名称 = 参数与内容[0], 参数内容 = 参数与内容[1] }); + } + catch (Exception) + { + + Debug.WriteLine($"[Debug]{DateTime.Now}|解析参数错误{e}"); + } + if (参数与内容[0] == "id") { 结果网址 += $"{参数与内容[0]}={参数与内容[1]}";