PC Review


Reply
Thread Tools Rate Thread

Cell cursor neglect cellinfo.

 
 
Joergen Bondesen
Guest
Posts: n/a
 
      11th Nov 2008
Hi NG



I have an odd problem.



Sometimes I get a spreadsheet with records, e.g. 50000 pcs.

Column 2 seems empty, so I mark cell B1 and use key: End - arrow down.

Normally cell cursor stops at the first cell with info, but sometimes the
cell cursor goes to sheet button, so I think the column is empty and then
delete the column and thereby customerinformations.

Any suggestion to how I can avoid this problem?


--
Best Regards
Joergen Bondesen



 
Reply With Quote
 
 
 
 
Ken
Guest
Posts: n/a
 
      11th Nov 2008
Joergen

How are you deleting the column? If you do as I often do and hit
control space to highlight the column, alt edit delete, you may
inadvertantly delete additional data if you have any cells in column B
merged with cells in A or C since the control space will select any
columns that are merged with column B.

Where is your data that is deleted before it gets deleted? it seems
like deleting an empty column should not cause any loss of data; and
if end-down arrow takes you all the way to the bottom, the column is
either empty or full, and if it is full of data you would probably
know that.

Ken


On Nov 11, 2:45*pm, "Joergen Bondesen" <bonde...@cool.dk> wrote:
> Hi NG
>
> I have an odd problem.
>
> Sometimes I get a spreadsheet with records, e.g. 50000 pcs.
>
> Column 2 seems empty, so I mark cell B1 and use key: End - arrow down.
>
> Normally cell cursor stops at the first cell with info, but sometimes the
> cell cursor goes to sheet button, so I think the column is empty and then
> delete the column and thereby customerinformations.
>
> Any suggestion to how I can avoid this problem?
>
> --
> Best Regards
> Joergen Bondesen


 
Reply With Quote
 
Joergen Bondesen
Guest
Posts: n/a
 
      12th Nov 2008
Hi Ken

Excuse my insufficient explanation.

I have 2 Columns A and B with 50000 Records.
Column A and B contains text (no formula).
In Column A contain all cells information.
In column B contain cell B2500 = test.

I select cell B1 and use key: End - arrow down.

Normally cell cursor stops at the first cell with info (B2500),
but sometimes the cell cursor goes to sheet button,
so I think the column is empty and then delete the column
and thereby customerinformations, in this case B2500 = test.

Is there a way to make the curser able to stop at B2500?

--
Best regards
Joergen Bondesen


"Ken" <(E-Mail Removed)> skrev i en meddelelse
news:bf2841ff-0a7a-4cfd-bd5f-(E-Mail Removed)...
Joergen

How are you deleting the column? If you do as I often do and hit
control space to highlight the column, alt edit delete, you may
inadvertantly delete additional data if you have any cells in column B
merged with cells in A or C since the control space will select any
columns that are merged with column B.

Where is your data that is deleted before it gets deleted? it seems
like deleting an empty column should not cause any loss of data; and
if end-down arrow takes you all the way to the bottom, the column is
either empty or full, and if it is full of data you would probably
know that.

Ken


On Nov 11, 2:45 pm, "Joergen Bondesen" <bonde...@cool.dk> wrote:
> Hi NG
>
> I have an odd problem.
>
> Sometimes I get a spreadsheet with records, e.g. 50000 pcs.
>
> Column 2 seems empty, so I mark cell B1 and use key: End - arrow down.
>
> Normally cell cursor stops at the first cell with info, but sometimes the
> cell cursor goes to sheet button, so I think the column is empty and then
> delete the column and thereby customerinformations.
>
> Any suggestion to how I can avoid this problem?
>
> --
> Best Regards
> Joergen Bondesen



 
Reply With Quote
 
Joergen Bondesen
Guest
Posts: n/a
 
      12th Nov 2008
Hi Ken

Below macro makes it possible for me to use 'End - key down' with success.

The remaining question is, why this problem.



Option Explicit


'----------------------------------------------------------
' Procedure : AvoidNoneSelect
' Date : 20081112
' Author : Joergen Bondesen
' Modifyed by :
' Purpose : To avoid none select first cell with info.
' Note : Only sometimes in customer excelfiles.
'----------------------------------------------------------
'
Sub AvoidNoneSelect()
Dim rrange As Range
Set rrange = Selection

Dim cell As Range
For Each cell In rrange
If Trim(cell.Value) = vbNullString Then
cell.Value = "'"
cell.Value = vbNullString
End If
Next cell
Set rrange = Nothing
End Sub

--
Best Regards
Joergen Bondesen


"Joergen Bondesen" <(E-Mail Removed)> skrev i en meddelelse
news:(E-Mail Removed)...
> Hi Ken
>
> Excuse my insufficient explanation.
>
> I have 2 Columns A and B with 50000 Records.
> Column A and B contains text (no formula).
> In Column A contain all cells information.
> In column B contain cell B2500 = test.
>
> I select cell B1 and use key: End - arrow down.
>
> Normally cell cursor stops at the first cell with info (B2500),
> but sometimes the cell cursor goes to sheet button,
> so I think the column is empty and then delete the column
> and thereby customerinformations, in this case B2500 = test.
>
> Is there a way to make the curser able to stop at B2500?
>
> --
> Best regards
> Joergen Bondesen
>
>
> "Ken" <(E-Mail Removed)> skrev i en meddelelse
> news:bf2841ff-0a7a-4cfd-bd5f-(E-Mail Removed)...
> Joergen
>
> How are you deleting the column? If you do as I often do and hit
> control space to highlight the column, alt edit delete, you may
> inadvertantly delete additional data if you have any cells in column B
> merged with cells in A or C since the control space will select any
> columns that are merged with column B.
>
> Where is your data that is deleted before it gets deleted? it seems
> like deleting an empty column should not cause any loss of data; and
> if end-down arrow takes you all the way to the bottom, the column is
> either empty or full, and if it is full of data you would probably
> know that.
>
> Ken
>
>
> On Nov 11, 2:45 pm, "Joergen Bondesen" <bonde...@cool.dk> wrote:
>> Hi NG
>>
>> I have an odd problem.
>>
>> Sometimes I get a spreadsheet with records, e.g. 50000 pcs.
>>
>> Column 2 seems empty, so I mark cell B1 and use key: End - arrow down.
>>
>> Normally cell cursor stops at the first cell with info, but sometimes the
>> cell cursor goes to sheet button, so I think the column is empty and then
>> delete the column and thereby customerinformations.
>>
>> Any suggestion to how I can avoid this problem?
>>
>> --
>> Best Regards
>> Joergen Bondesen

>
>



 
Reply With Quote
 
Ken
Guest
Posts: n/a
 
      12th Nov 2008
Joergen

It seems like what appears to be empty is not really empty. The trim
function will remove leading and trailing spaces, so your macro will
replace the cell value with vbNullString (make it really empty) if, in
fact, all that was there was a space (or multiple spaces). I believe
that cell.value="'" is extraneous.

If you edit a seemingly empty cell (before running your macro) you
will probably see that it contains a space. After the macro runs what
looked like it was empty is really empty, so the end-arrow
functionality then performs as you expect.

Good luck.

Ken
Norfolk, Va



On Nov 12, 3:38*pm, "Joergen Bondesen" <bonde...@cool.dk> wrote:
> Hi Ken
>
> Below macro makes it possible for me to use 'End - key down' with success..
>
> The remaining question is, why this problem.
>
> Option Explicit
>
> '----------------------------------------------------------
> ' Procedure * : AvoidNoneSelect
> ' Date * * * *: 20081112
> ' Author * * *: Joergen Bondesen
> ' Modifyed by :
> ' Purpose * * : To avoid none select first cell with info.
> ' Note * * * *: Only sometimes in customer excelfiles.
> '----------------------------------------------------------
> '
> Sub AvoidNoneSelect()
> * Dim rrange As Range
> * Set rrange = Selection
>
> * Dim cell As Range
> * For Each cell In rrange
> * * If Trim(cell.Value) = vbNullString Then
> * * * cell.Value = "'"
> * * * cell.Value = vbNullString
> * * End If
> * Next cell
> * Set rrange = Nothing
> End Sub
>
> --
> Best Regards
> Joergen Bondesen
>
> "Joergen Bondesen" <bonde...@cool.dk> skrev i en meddelelsenews:(E-Mail Removed)...
>
>
>
> > Hi Ken

>
> > Excuse my insufficient explanation.

>
> > I have 2 Columns A and B with 50000 Records.
> > Column A and B contains text (no formula).
> > In Column A contain all cells information.
> > In column B contain cell B2500 = test.

>
> > I select cell B1 and use key: End - arrow down.

>
> > Normally cell cursor stops at the first cell with info (B2500),
> > but sometimes the cell cursor goes to sheet button,
> > so I think the column is empty and then delete the column
> > and thereby customerinformations, in this case B2500 = test.

>
> > Is there a way to make the curser able to stop at B2500?

>
> > --
> > Best regards
> > Joergen Bondesen

>
> > "Ken" <krco...@aol.com> skrev i en meddelelse
> >news:bf2841ff-0a7a-4cfd-bd5f-(E-Mail Removed)....
> > Joergen

>
> > How are you deleting the column? *If you do as I often do and hit
> > control space to highlight the column, alt edit delete, you may
> > inadvertantly delete additional data if you have any cells in column B
> > merged with cells in A or C since the control space will select any
> > columns that are merged with column B.

>
> > Where is your data that is deleted before it gets deleted? *it seems
> > like deleting an empty column should not cause any loss of data; and
> > if end-down arrow takes you all the way to the bottom, the column is
> > either empty or full, and if it is full of data you would probably
> > know that.

>
> > Ken

>
> > On Nov 11, 2:45 pm, "Joergen Bondesen" <bonde...@cool.dk> wrote:
> >> Hi NG

>
> >> I have an odd problem.

>
> >> Sometimes I get a spreadsheet with records, e.g. 50000 pcs.

>
> >> Column 2 seems empty, so I mark cell B1 and use key: End - arrow down.

>
> >> Normally cell cursor stops at the first cell with info, but sometimes the
> >> cell cursor goes to sheet button, so I think the column is empty and then
> >> delete the column and thereby customerinformations.

>
> >> Any suggestion to how I can avoid this problem?

>
> >> --
> >> Best Regards
> >> Joergen Bondesen- Hide quoted text -

>
> - Show quoted text -


 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Putting Cursor in Cell A1 of each Worksheet, then ending cursor on smalest sheet name according to VBA Editor Matt Microsoft Excel Programming 1 14th May 2007 09:21 AM
Child Neglect wASP Microsoft C# .NET 1 9th Aug 2005 08:00 PM
Child Neglect wASP Microsoft Dot NET 2 9th Aug 2005 07:58 PM
Child Neglect wASP Microsoft ASP .NET 4 9th Aug 2005 07:41 PM
Why Neglect .Net Remoting Howard Swope Microsoft Dot NET Compact Framework 5 27th Dec 2004 10:29 AM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 11:08 PM.