使用变量来定义范围(“???”)中的行号。选择 [英] Use a variable to define the row number in a Range ("???").select

查看:78
本文介绍了使用变量来定义范围(“???”)中的行号。选择的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

Dim r为整数


r = 5


范围("G r")。选择




这个档位有'范围'_Global失败


我想要操纵r(逻辑生成的行)并用于选择单元格


帮助...修复

解决方案

< BLOCKQUOTE>

回复:&NBSP;指定范围

'---

Dim r As Long

r = 5



单元格(r,"G")。选择


- 或 -


范围("G"& r)。选择


'---

Jim Cone < br $> b $ b美国俄勒冈州波特兰市
https://goo.gl/IUQUN2 &NBSP;(收存箱)

Dim r as integer

r=5

Range("G r").select

This stalls with 'Range' _Global fail

I want to manipulate r (the row that logic produces) and use to select a cell

Help...fix

解决方案

Re:  specify a range
'---
Dim r As Long
r = 5

Cells(r, "G").Select

-or-

Range("G" & r).Select

'---

Jim Cone
Portland, Oregon USA
https://goo.gl/IUQUN2 (Dropbox)


这篇关于使用变量来定义范围(“???”)中的行号。选择的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆