一个批量处理数组的方法(downmoon原创)

Batch脚本数组使用指南:深入掌握数组操作技巧 虽然Batch脚本没有内置的数组支持,但通过一些创造性的方法,我们仍然可以在Batch脚本中有效地使用数组。本文详细介绍了如何在Batch脚本中创建、初始化、访问、遍历、扩展、收缩数组,以及如何模拟多维数组。此外,还探讨了数组的局限性和一些实际应用案例。掌握Batch脚本中的数组使用技巧对于编写高效的自动化脚本至关重要。通过本文的学习,读者应该能够理解Batch脚本中数组操作的基本概念和方法,并能够将这些知识应用到实际的脚本编写中。 阅读详情

一个批量处理数组的方法

#region Send MobileMessage By userList 
        
/// <summary>
        
/// Send MobileMessage By userList 
        
/// Tony 2007-05-31
        
/// <param name="site">Site</param>
        
/// <param name="lng">lng</param>
        
/// <param name="UserList">userList</param>
        
/// <param name="SendContent">SendContent</param>
        
/// <param name="MobileSource">1为PassPort,1为Message</param>
        public static  void SendToMobileByUserList(string site,string lng,string [] UserList,string SendContent,short MobileSource)
        {
            
if(UserList ==null || UserList.Length==0 )
            {
return;}
            
else
            {
                
if(IsLoginWithSite(site.Trim()))
                {
                    
try
                    {
                        
#region 定义变量
                        SendHistory s;
                        StringBuilder sb 
= new StringBuilder();
                        
//组内计数
                        int LevelCount=0;
                        
//数组长度
                        int userLen=UserList.Length;
                        
string temp1 = string.Empty;
                        
//当前组序号
                        int CurrentLevel=0;
                        
//总的组数(取整) such as 8/3=2
                        
//MaxBatchMobileNumber为外部public Vars,每批处理的数量
                        int MaxLevel=userLen/MaxBatchMobileNumber;
                        PassPort.User2007.Framework.Components.User2007 ur;
                        PassPortWebService pws
=new PassPortWebService();
                        MobileMessageSet m;
                        
string m1;
                        
#endregion
                        
foreach(string u in UserList)
                        {
                            
if(u==null || u.Trim().Length==0)
                            {
                                
//组内计数加一
                                LevelCount++;
                                
continue;
                            }
                            
#region 获取一串手机号码
                            
switch (MobileSource)
                            {
                                
case 1:
                                    
#region 从Passport获取号码
                                    ur
=pws.GetUser2007(u,lng);
                                    
if(ur!=null  &&  ur.Mobile!=null)  
                                    {
                                        m1
=string.Empty;
                                        m1
=GetMobileStartWith13(ur.Mobile.Trim());
                                        
if(m1.Length>10)
                                        {sb.Append(m1
+",");}
                                    }
                                    ur
=null;
                                    
#endregion
                                    
break;
                                
case 2:
                                    
#region 从短信提醒设置获取号码
                                    m
=SMS.MobileMessageSet.Framework.Data.DataDTOProvider.MobileMessageSetSelectByLoginID(0,u,lng);
                                    
if(m!=null && m.ToMobile!=null )
                                    {
                                        m1
=string.Empty;
                                        m1
=GetMobileStartWith13(m.ToMobile);
                                        
if(m1.Length>10)
                                        {sb.Append(m1
+",");    }
                                    }
                                    m
=null;
                                    
#endregion
                                    
break;
                                
default:
                                    
#region 从Passport获取号码
                                    ur
=pws.GetUser2007(u,lng);
                                    
if(ur!=null  &&  ur.Mobile!=null)  
                                    {
                                        m1
=string.Empty;
                                        m1
=GetMobileStartWith13(ur.Mobile.Trim());
                                        
if(m1.Length>10)
                                        {sb.Append(m1
+",");}
                                    }
                                    ur
=null;
                                    
#endregion
                                    
break;
                            }
                            
//组内计数加一
                            LevelCount++;
                            
#endregion
                            
#region 发送一批号码
                            
                            
if(LevelCount==userLen && LevelCount<MaxBatchMobileNumber)
                            {
                                
#region 用户数量小于批数量
                                temp1
=sb.ToString();                                
                                
if(temp1.EndsWith(","))
                                {
                                    temp1
=temp1.Remove(temp1.Length-1,1);
                                }
                                
int bRtn = new JL().SendMsg(pHandle,strMobileCode,temp1,SendContent,"");
                                
#region 发送成功后写入数据库
                                
if(bRtn==0)
                                {
                                    s
=new SendHistory();
                                    s.MessageID
=-100;
                                    s.Status
=0;
                                    lng
=(lng==null || lng.Trim().Length==0)?"cn":lng;
                                
                                    
string str="来自于{0},语言为{1},发送给{2}的手机({3})的短信内容:{4}";
                                    s.Topic
=string.Format(str,site,lng,u,temp1,SendContent);;
                                    s.CreatTime
=DateTime.Now;
                                    s.F1
=0;
                                    s.F2
=0;
                                    s.F3
=site+"-"+lng;
                                    s.F4
="";
                                    s.UpdateTime
=DateTime.Now;
                                    SMS.SendHistory.Framework.Data.DataDTOProvider.SendHistoryInsert(s);
                                    s
=null;
                                }
                                
#endregion
                                
#region 完成后清零
                                sb
=new StringBuilder();
                                temp1
=string.Empty;
                                LevelCount
=0;
                                
#endregion
                                
#endregion
                            }
                            
else if (LevelCount == MaxBatchMobileNumber)
                            {
                                
#region 刚好一批
                                temp1
=sb.ToString();                                
                                
if(temp1.EndsWith(","))
                                {
                                    temp1
=temp1.Remove(temp1.Length-1,1);
                                }
                                
int bRtn = new JL().SendMsg(pHandle,strMobileCode,temp1,SendContent,"");
                                
#region 发送成功后写入数据库
                                
if(bRtn==0)
                                {
                                    s
=new SendHistory();
                                    s.MessageID
=-100;
                                    s.Status
=0;
                                    lng
=(lng==null || lng.Trim().Length==0)?"cn":lng;
                                
                                    
string str="来自于{0},语言为{1},发送给{2}的手机({3})的短信内容:{4}";
                                    s.Topic
=string.Format(str,site,lng,u,temp1,SendContent);;
                                    s.CreatTime
=DateTime.Now;
                                    s.F1
=0;
                                    s.F2
=0;
                                    s.F3
=site+"-"+lng;
                                    s.F4
="";
                                    s.UpdateTime
=DateTime.Now;
                                    SMS.SendHistory.Framework.Data.DataDTOProvider.SendHistoryInsert(s);
                                    s
=null;
                                }
                                
#endregion
                                
#region 完成后清零
                                sb
=new StringBuilder();
                                temp1
=string.Empty;
                                LevelCount
=0;
                                
//当前组数加一
                                CurrentLevel++;
                                
#endregion
                                
#endregion
                            }
                            
else if(LevelCount<MaxBatchMobileNumber   && (userLen%MaxBatchMobileNumber)==LevelCount && MaxLevel==CurrentLevel)
                            {
                                
#region 最后一批
                                temp1
=sb.ToString();                                
                                
if(temp1.EndsWith(","))
                                {
                                    temp1
=temp1.Remove(temp1.Length-1,1);
                                }
                                
int bRtn = new JL().SendMsg(pHandle,strMobileCode,temp1,SendContent,"");
                                
#region 发送成功后写入数据库
                                
if(bRtn==0)
                                {
                                    s
=new SendHistory();
                                    s.MessageID
=-100;
                                    s.Status
=0;
                                    lng
=(lng==null || lng.Trim().Length==0)?"cn":lng;
                                
                                    
string str="来自于{0},语言为{1},发送给{2}的手机({3})的短信内容:{4}";
                                    s.Topic
=string.Format(str,site,lng,u,temp1,SendContent);;
                                    s.CreatTime
=DateTime.Now;
                                    s.F1
=0;
                                    s.F2
=0;
                                    s.F3
=site+"-"+lng;
                                    s.F4
="";
                                    s.UpdateTime
=DateTime.Now;
                                    SMS.SendHistory.Framework.Data.DataDTOProvider.SendHistoryInsert(s);
                                    s
=null;
                                }
                                
#endregion
                                
#region 完成后清零
                                sb
=new StringBuilder();
                                temp1
=string.Empty;
                                LevelCount
=0;
                                
#endregion
                                
#endregion

                            }
                            
#endregion
                        }
                    }
                    
catch //(Exception ex)
                    {
                        
return;
                    }
                }
            }
        }
                
        
#endregion
BAT批处理中使用数组示例 主要介绍了BAT批处理中使用数组示例,批处理指令中并没有原生支持数组,本文用模拟的方法实现数组类似效果,需要的朋友可以参考下 立即下载

相关推荐

低供电电压CMOS偏置电路分析(有些类似于三支路电流源)

1、偏置电路原理图以及仿真结果 电路电流分析:Ip=Ip1=Ip2=Ip3,那么 Ip=12μnCoxWL(IpR−VTH)2 I_p=\frac{1}{2} μ_nC_{ox}\frac{W}{L} (I_{p}R-V_{TH})^2 Ip​=21​μn​Cox​LW​(Ip​R−VTH​)2 解出方程式即可得到参考电流及参考电压 2、电路电源抑制比PSRR分析 这里为了方便,小信号前都不加△ 首先做一个近似,由于gmRo>>1,直接将VDD变化导致的P3管漏级电压变化与VDD变化量做相等

qq_46579389的博客 2906

批处理(bat)中的数组问题

批处理的数组操作

蚂蚁小兵 2万+

VLA-JEPA:具身智能中潜空间世界模型的工程落地实践

世界模型是具身智能实现环境理解与因果推演的核心基础,其本质是在状态空间中建模‘动作→结果’的动力学规律。传统基于像素或文本的世界模型因高维、非平稳、弱语义等缺陷,在真实机器人场景中鲁棒性差、部署成本高。JEPA(联合嵌入预测架构)通过构建物理约束的潜空间,将视觉-语言-动作(VLA)信号统一编码为低维、可微、可解释的状态表征,显著提升模型对抖动、遮挡、光照突变等干扰的适应能力,并支持实时闭环控制。该范式已在UR5e、Franka等多构型机械臂及Jetson边缘平台完成实测验证,成为VLA系统从实验室走向产线

weixin_34357928的博客 336

Windows批处理 实现数组方法

Windows的批处理没有提供数组这个数据结构,所以自己手动编写了Bat相关的数组过程,方便在Bat中使用数组这个基本数据结构。表达式类似C语言的数组。   点击此处下载该cmd库文件 使用数组,如下格式:        Set 变量名[下标]=值   下面是数组的相关函数 Array        初始化一个数组。         格式 Array  输入_数组名字 Fr

Linux/Unix 菜园 2万+

使用LogisticRegression和LightGBM模型对信贷违约进行预测----基于kaggle比赛数据

3.分离数值型变量与类别型变量,发现有些数值型变量因为输入不规范,比如数值中含有字符(28_,_10000_等)被划分为类别型变量 ,比如 'Age','Annual_Income','Num_of_Loan', 'Num_of_Delayed_Payment', 'Changed_Credit_Limit','Credit_Mix','Monthly_Balance', 'Outstanding_Debt' ,'Amount_invested_monthly'等。三、分箱,woe编码,计算IV值。

I_am_a_big_tiger的博客 1682

Android Studio打包全攻略---从入门到精通

初出茅庐 手动打包怎么手动打包项目写完了,现在需要把应用上传到市场,问题出现—怎么把代码变成.apk(Android的可安装文件)。 1. 创建签名文件 2. 填写好签名参数 3. 生成APK 注意:签名的密码和密匙的密码注意保管,不要忘了,签名文件别泄漏了,也别搞丢了为什么要打包我最开始就有这个疑问,我们的代码不是点了下运行按钮就直接安装到手机上了吗,我们在在项目Project

我早就想,要这样载着你,翻山越岭 2万+

批处理模拟一维数组

代码如下: @echo off setlocal ENABLEDELAYEDEXPANSION set tmp="30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1" set tmp1="10 9 8 7 6 5 4 3 2 1" call:fun_arr %tmp% array l

end1n9的专栏 7925

基于STM32的无人机智能避障与路径规划系统设计

本文详细介绍了基于STM32的无人机智能避障与路径规划系统设计,涵盖硬件选型、传感器组合、软件架构及算法实现。通过多传感器数据融合和改进的VFH+算法,系统在复杂环境中实现92%以上的避障成功率。STM32微控制器的实时性和低功耗特性为无人机自主导航提供了可靠保障,适用于工业巡检、仓储物流等场景。

blockchain9miner的博客 875

bat批处理中使用数组示例_在PHP教程中使用示例计算数组长度

bat批处理中使用数组示例PHP programming language provides the count(), sizeof() functions and foreach in order to count the elements in an array. The array can be a single dimension or multidimensional array. PH...

cunjiu9486的博客 1010

嵌入式Linux&Android开发-TP调试

目录 一、修改DTS,添加新的I2C设备 二、修改Makefile,Kconfig 三、tp调试时的问题排查 一、修改DTS,添加新的I2C设备 &i2c4 { status = "okay"; clock-frequency = <400000>; gslX680@40 { compatible = "gslX680"; reg = <0x40>; touch-gpio = <&gp

嵌入式成长手册 570

手把手教你学Simulink--Simulink智能驾驶场景挑战:高速公路入口匝道汇入仿真

高速公路入口匝道汇入在智能驾驶中的作用是当车辆从入口匝道进入主干道时,系统能够自主决策并执行汇入操作,确保安全和高效。目标识别与跟踪:如检测前方障碍物、识别车道线。路径规划:如计算最优汇入路径。动态控制:如调整速度、转向等以完成汇入动作。本示例将展示如何使用Simulink构建一个用于智能车辆高速公路入口匝道汇入的仿真模型,并进行验证。通过本指南,我们介绍了如何基于Simulink搭建一个用于智能车辆高速公路入口匝道汇入的仿真模型,并进行仿真和性能评估。背景介绍。

MHD0815的博客 261

获取远程网页的内容之二(downmoon原创)

本机直接上网时,请参看获取远程网页的内容之一(downmoon原创) 本文仅针AD下代理上网的情况: 代码如下: 1、定义变量:&lt;!-- .lineBorderBlue1 { BORDER-TOP: #999999 1px groove; BORDER-BOTTOM: #999999 1px groove; BORDER-LEFT: #999999 1...

ribishuangba 93

利用Python实现Springer文献关键词爬虫

🔧 如何分析Springer的搜索结果HTML结构🕷️ 编写高性能异步爬虫抓取论文元数据📊 使用Pandas导出Excel🧠 如何处理作者、摘要、DOI等字段🔄 如何优化爬虫稳定性与可扩展性。

2201_76125261的博客 414

返回一行中相对数字比较集中最后的一个索引位置(downmoon)

有人问起这个问题: 有字符串如下: ds32Christchurch 2 b 1200 - Rosamond J.S3. ston 2 a 916 - Sidney 34 5 a 408 - Thomas A. 12 Youkq k 3hitehaven 10 b 1317 要求返回一行中相对数字比较集中最后的一个索引 以上结果应为 1200 后面的第一个位置 916 后面...

ribishuangba 105

Data-Structures-and-Algorithm-Analysis-in-Java.pdf

作者: Weiss, Mark A. 出版社: Addison Wesley Data Structures and Algorithm Analysis in Java is an “advanced algorithms” book that fits between traditional CS2 and Algorithms Analysis courses. In the old ACM Curriculum Guidelines, this course was known as CS7. This text is for readers who want to learn good programming and algorithm analysis skills simultaneously so that they can develop such programs with the maximum amo...

深度学习工具包 DeepLearningToolbox

深度学习工具包Deprecation notice.-----This toolbox is outdated and no longer maintained.There are much better tools available for deep learning than this toolbox, e.g. [Theano](http://deeplearning.net/software/theano/), [torch](http://torch.ch/) or [tensorflow](http://www.tensorflow.org/)I would suggest you use one of the tools mentioned above rather than use this toolbox.Best, Rasmus.DeepLearnToolbox================A Matlab toolbox for Deep Learning.Deep Learning is a new subfield of machine learning that focuses on learning deep hierarchical models of data.It is inspired by the human brain's apparent deep (layered, hierarchical) architecture.A good overview of the theory of Deep Learning theory is[Learning Deep Architectures for AI](http://www.iro.umontreal.ca/~bengioy/papers/ftml_book.pdf)For a more informal introduction, see the following videos by Geoffrey Hinton and Andrew Ng.* [The Next Generation of Neural Networks](http://www.youtube.com/watch?v=AyzOUbkUf3M) (Hinton, 2007)* [Recent Developments in Deep Learning](http://www.youtube.com/watch?v=VdIURAu1-aU) (Hinton, 2010)* [Unsupervised Feature Learning and Deep Learning](http://www.youtube.com/watch?v=ZmNOAtZIgIk) (Ng, 2011)If you use this toolbox in your research please cite [Prediction as a candidate for learning deep hierarchical models of data](http://www2.imm.dtu.dk/pubdb/views/publication_details.php?id=6284)```@MASTERSTHESIS\{IMM2012-06284, author = "R. B. Palm", title = "Prediction as a candidate for learning deep hierarchical models of data", year = "2012",}```Contact: rasmusbergpalm at gmail dot comDirectories included in the toolbox-----------------------------------`NN/` - A library for Feedforward Backpropagation Neural Networks`CNN/` - A library for Convolutional Neural Networks`DBN/` - A library for Deep Belief Networks`SAE/` - A library for Stacked Auto-Encoders`CAE/` - A library for Convolutional Auto-Encoders`util/` - Utility functions used by the libraries`data/` - Data used by the examples`tests/` - unit tests to verify toolbox is workingFor references on each library check REFS.mdSetup-----1. Download.2. addpath(genpath('DeepLearnToolbox'));Example: Deep Belief Network---------------------```matlabfunction test_example_DBNload mnist_uint8;train_x = double(train_x) / 255;test_x = double(test_x) / 255;train_y = double(train_y);test_y = double(test_y);%% ex1 train a 100 hidden unit RBM and visualize its weightsrand('state',0)dbn.sizes = [100];opts.numepochs = 1;opts.batchsize = 100;opts.momentum = 0;opts.alpha = 1;dbn = dbnsetup(dbn, train_x, opts);dbn = dbntrain(dbn, train_x, opts);figure; visualize(dbn.rbm{1}.W'); % Visualize the RBM weights%% ex2 train a 100-100 hidden unit DBN and use its weights to initialize a NNrand('state',0)%train dbndbn.sizes = [100 100];opts.numepochs = 1;opts.batchsize = 100;opts.momentum = 0;opts.alpha = 1;dbn = dbnsetup(dbn, train_x, opts);dbn = dbntrain(dbn, train_x, opts);%unfold dbn to nnnn = dbnunfoldtonn(dbn, 10);nn.activation_function = 'sigm';%train nnopts.numepochs = 1;opts.batchsize = 100;nn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.10, 'Too big error');```Example: Stacked Auto-Encoders---------------------```matlabfunction test_example_SAEload mnist_uint8;train_x = double(train_x)/255;test_x = double(test_x)/255;train_y = double(train_y);test_y = double(test_y);%% ex1 train a 100 hidden unit SDAE and use it to initialize a FFNN% Setup and train a stacked denoising autoencoder (SDAE)rand('state',0)sae = saesetup([784 100]);sae.ae{1}.activation_function = 'sigm';sae.ae{1}.learningRate = 1;sae.ae{1}.inputZeroMaskedFraction = 0.5;opts.numepochs = 1;opts.batchsize = 100;sae = saetrain(sae, train_x, opts);visualize(sae.ae{1}.W{1}(:,2:end)')% Use the SDAE to initialize a FFNNnn = nnsetup([784 100 10]);nn.activation_function = 'sigm';nn.learningRate = 1;nn.W{1} = sae.ae{1}.W{1};% Train the FFNNopts.numepochs = 1;opts.batchsize = 100;nn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.16, 'Too big error');```Example: Convolutional Neural Nets---------------------```matlabfunction test_example_CNNload mnist_uint8;train_x = double(reshape(train_x',28,28,60000))/255;test_x = double(reshape(test_x',28,28,10000))/255;train_y = double(train_y');test_y = double(test_y');%% ex1 Train a 6c-2s-12c-2s Convolutional neural network %will run 1 epoch in about 200 second and get around 11% error. %With 100 epochs you'll get around 1.2% errorrand('state',0)cnn.layers = { struct('type', 'i') %input layer struct('type', 'c', 'outputmaps', 6, 'kernelsize', 5) %convolution layer struct('type', 's', 'scale', 2) %sub sampling layer struct('type', 'c', 'outputmaps', 12, 'kernelsize', 5) %convolution layer struct('type', 's', 'scale', 2) %subsampling layer};cnn = cnnsetup(cnn, train_x, train_y);opts.alpha = 1;opts.batchsize = 50;opts.numepochs = 1;cnn = cnntrain(cnn, train_x, train_y, opts);[er, bad] = cnntest(cnn, test_x, test_y);%plot mean squared errorfigure; plot(cnn.rL);assert(er<0.12, 'Too big error');```Example: Neural Networks---------------------```matlabfunction test_example_NNload mnist_uint8;train_x = double(train_x) / 255;test_x = double(test_x) / 255;train_y = double(train_y);test_y = double(test_y);% normalize[train_x, mu, sigma] = zscore(train_x);test_x = normalize(test_x, mu, sigma);%% ex1 vanilla neural netrand('state',0)nn = nnsetup([784 100 10]);opts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samples[nn, L] = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.08, 'Too big error');%% ex2 neural net with L2 weight decayrand('state',0)nn = nnsetup([784 100 10]);nn.weightPenaltyL2 = 1e-4; % L2 weight decayopts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samplesnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex3 neural net with dropoutrand('state',0)nn = nnsetup([784 100 10]);nn.dropoutFraction = 0.5; % Dropout fraction opts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samplesnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex4 neural net with sigmoid activation functionrand('state',0)nn = nnsetup([784 100 10]);nn.activation_function = 'sigm'; % Sigmoid activation functionnn.learningRate = 1; % Sigm require a lower learning rateopts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samplesnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex5 plotting functionalityrand('state',0)nn = nnsetup([784 20 10]);opts.numepochs = 5; % Number of full sweeps through datann.output = 'softmax'; % use softmax outputopts.batchsize = 1000; % Take a mean gradient step over this many samplesopts.plot = 1; % enable plottingnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex6 neural net with sigmoid activation and plotting of validation and training error% split training data into training and validation datavx = train_x(1:10000,:);tx = train_x(10001:end,:);vy = train_y(1:10000,:);ty = train_y(10001:end,:);rand('state',0)nn = nnsetup([784 20 10]); nn.output = 'softmax'; % use softmax outputopts.numepochs = 5; % Number of full sweeps through dataopts.batchsize = 1000; % Take a mean gradient step over this many samplesopts.plot = 1; % enable plottingnn = nntrain(nn, tx, ty, opts, vx, vy); % nntrain takes validation set as last two arguments (optionally)[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');```[![Bitdeli Badge](https://d2weczhvl823v0.cloudfront.net/rasmusbergpalm/deeplearntoolbox/trend.png)](https://bitdeli.com/free "Bitdeli Badge")

c#中通过值和引用传递参数(downmoon)

c#中通过值和引用传递参数(downmoon) 在 C# 中,既可以通过值也可以通过引用传递参数。通过引用传递参数允许函数成员(方法、属性、索引器、运算符和构造函数)更改参数的值,并保持该更改。若要通过引用传递参数,请使用 ref 或 out 关键字。为简单起见,本主题的示例中只使用了 ref 关键字。有关 ref 和 out 之间的差异的信息,请参见、使用 ref 和 out 传递数

pp_zz的专栏 481

大中型超市收银系统(可直接运行)

光步前台收银系统系统功能:商品销售、商品退货、挂单、收银员权限、会员销售、单品取消、整单取消、商品查询、脱机销售、脱机数据上传,基本资料下载,开钱箱、小票打印、收款结算,支持多币种付款方式(现金、储值卡、礼券、微信等),支持多种促销。运行环境:.net 4.0登陆信息用户名:1001 密码:123456内置商品信息,商品编码可输入00001000 - 00010000,测试效果相关功能键F5 结算 F9挂单 F11商品查询 F8退货 Insert单品取消 Del整单取消 F12开钱箱F2 会员 Ctrl+Z退出系统 Home 锁屏 相关源码待公开

上一篇: IIS 6进程CPU占用率50%,一段时间后,网站崩掉,如何处理? (downmoon)
下一篇: 一个动态菜单的例子(downmoon)
downmoon
博客等级 码龄24年 1676粉丝 494原创
评论
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符
 
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

个

红包个数最小为10个

元

红包金额最低5元

当前余额3.43元 前往充值 >
需支付:10.00元
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付元
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值