本文介绍了嵌套循环不起作用的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

您好,

我正在尝试创建一个嵌套循环(在Access 2003 / VB中),该循环将在表单上打印一组用户定义月份的报告,并打印出来每个客户。因此,第一个循环会将客户端增加1,然后第二个循环会将Month增加1.因此第一次围绕第1个月的客户端A,然后是第2个月的客户端A,然后是第1个月的客户端B,依此类推。下面是我已经拥有的,我可以让嵌套循环工作并增加月份,但是我有一点时间增加外部循环(客户端)。以下是我的代码。在此先感谢您的帮助。

Hello,
I am attempting to create a nested loop (in Access 2003/VB) that will print a report for a set of user defined months inputed on a form and that will print out for every Client. So the first loop would increment the Client by 1, then the second loop would increment the Month by 1. So the first time around Client A for Month 1, then Client A for month 2 then Client B for Month 1 and so on. Below is what I have already, I can get the nested loop to work and increment the months, but am having a heck of a time incrementing the outer loop (Client). Below is my code so far. Thanks in advance for your help.

展开 | 选择 | Wrap | 行号

推荐答案

展开 | 选择 | Wrap | 行号


展开 | 选择 | Wrap | 行号




抱歉,我不能提供更多帮助,但您是否尝试过测试Client_All.ItemData(i)而不是Client_Box.ItemData(i)的建议循环直到?换句话说......

Sorry I can''t be of more help, but did you try the suggestion of testing Client_All.ItemData(i) instead of Client_Box.ItemData(i) in the Loop Until? In other words...

展开 | 选择 | Wrap | 行号


这篇关于嵌套循环不起作用的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

05-28 06:58
查看更多