when I type
range("A1").select
I get error 1004
why?
Moiz
when I type
range("A1").select
I get error 1004
why?
Moiz
Hi Moiz,
The error would occur if the active sheet were not a worksheet but , say, a
chart sheet.
---
Regards,
Norman
"Moiz" <[email protected]> wrote in message
news:%23EGiV%[email protected]...
> when I type
>
> range("A1").select
>
> I get error 1004
>
> why?
>
> Moiz
>
It seems to accept Worksheets("Sheet1").Cell(1, 1).Select
but not
Range ("A1").Select
Any idea?
(it is not a chart sheet, and the Options/General is not set for RC)
"Norman Jones" <[email protected]> wrote in message
news:[email protected]...
> Hi Moiz,
>
> The error would occur if the active sheet were not a worksheet but , say,
> a chart sheet.
>
>
> ---
> Regards,
> Norman
>
>
>
> "Moiz" <[email protected]> wrote in message
> news:%23EGiV%[email protected]...
>> when I type
>>
>> range("A1").select
>>
>> I get error 1004
>>
>> why?
>>
>> Moiz
>>
>
>
It sounds like you have this code in the sheet module of a worksheet other
than Sheet1. If so, that is your problem. Likewise you could solve it with
Worksheets("Sheet1").Range("A1").Select
or
Activesheet.Range("A1").Select
Your solution was qualifying the range reference, not whether it was
Range("a1") or Cells(1,1)
--
regards,
Tom Ogilvy
"Moiz" <[email protected]> wrote in message
news:%[email protected]...
> It seems to accept Worksheets("Sheet1").Cell(1, 1).Select
>
> but not
>
> Range ("A1").Select
>
> Any idea?
> (it is not a chart sheet, and the Options/General is not set for RC)
>
> "Norman Jones" <[email protected]> wrote in message
> news:[email protected]...
> > Hi Moiz,
> >
> > The error would occur if the active sheet were not a worksheet but ,
say,
> > a chart sheet.
> >
> >
> > ---
> > Regards,
> > Norman
> >
> >
> >
> > "Moiz" <[email protected]> wrote in message
> > news:%23EGiV%[email protected]...
> >> when I type
> >>
> >> range("A1").select
> >>
> >> I get error 1004
> >>
> >> why?
> >>
> >> Moiz
> >>
> >
> >
>
>
I found the problem,
It was keeping the focus on a text box, not allowing the selection of a
different worksheet.
Thanks for your help.
Moiz
"Tom Ogilvy" <[email protected]> wrote in message
news:[email protected]...
> It sounds like you have this code in the sheet module of a worksheet other
> than Sheet1. If so, that is your problem. Likewise you could solve it
> with
>
> Worksheets("Sheet1").Range("A1").Select
>
> or
>
> Activesheet.Range("A1").Select
>
> Your solution was qualifying the range reference, not whether it was
> Range("a1") or Cells(1,1)
>
> --
> regards,
> Tom Ogilvy
>
>
>
> "Moiz" <[email protected]> wrote in message
> news:%[email protected]...
>> It seems to accept Worksheets("Sheet1").Cell(1, 1).Select
>>
>> but not
>>
>> Range ("A1").Select
>>
>> Any idea?
>> (it is not a chart sheet, and the Options/General is not set for RC)
>>
>> "Norman Jones" <[email protected]> wrote in message
>> news:[email protected]...
>> > Hi Moiz,
>> >
>> > The error would occur if the active sheet were not a worksheet but ,
> say,
>> > a chart sheet.
>> >
>> >
>> > ---
>> > Regards,
>> > Norman
>> >
>> >
>> >
>> > "Moiz" <[email protected]> wrote in message
>> > news:%23EGiV%[email protected]...
>> >> when I type
>> >>
>> >> range("A1").select
>> >>
>> >> I get error 1004
>> >>
>> >> why?
>> >>
>> >> Moiz
>> >>
>> >
>> >
>>
>>
>
>
Obviously that would be problematic for either
cells(1,1).Select
or
Range("A1").Select
But believe what you like.
--
Regards,
Tom Ogilvy
"Moiz" <[email protected]> wrote in message
news:[email protected]...
> I found the problem,
> It was keeping the focus on a text box, not allowing the selection of a
> different worksheet.
>
> Thanks for your help.
>
> Moiz
>
> "Tom Ogilvy" <[email protected]> wrote in message
> news:[email protected]...
> > It sounds like you have this code in the sheet module of a worksheet
other
> > than Sheet1. If so, that is your problem. Likewise you could solve it
> > with
> >
> > Worksheets("Sheet1").Range("A1").Select
> >
> > or
> >
> > Activesheet.Range("A1").Select
> >
> > Your solution was qualifying the range reference, not whether it was
> > Range("a1") or Cells(1,1)
> >
> > --
> > regards,
> > Tom Ogilvy
> >
> >
> >
> > "Moiz" <[email protected]> wrote in message
> > news:%[email protected]...
> >> It seems to accept Worksheets("Sheet1").Cell(1, 1).Select
> >>
> >> but not
> >>
> >> Range ("A1").Select
> >>
> >> Any idea?
> >> (it is not a chart sheet, and the Options/General is not set for RC)
> >>
> >> "Norman Jones" <[email protected]> wrote in message
> >> news:[email protected]...
> >> > Hi Moiz,
> >> >
> >> > The error would occur if the active sheet were not a worksheet but ,
> > say,
> >> > a chart sheet.
> >> >
> >> >
> >> > ---
> >> > Regards,
> >> > Norman
> >> >
> >> >
> >> >
> >> > "Moiz" <[email protected]> wrote in message
> >> > news:%23EGiV%[email protected]...
> >> >> when I type
> >> >>
> >> >> range("A1").select
> >> >>
> >> >> I get error 1004
> >> >>
> >> >> why?
> >> >>
> >> >> Moiz
> >> >>
> >> >
> >> >
> >>
> >>
> >
> >
>
>
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks