LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default error message 91 when entering wrong data


the following code is for updating a textbox on my form, but when
enter data that is not in the list i get an error.

Private Sub txtBestellingArtikelCode2_Change()

ActiveWorkbook.Sheets("artikelen").Activate
Cells.Find(What:=txtBestellingArtikelCode2.Value
After:=ActiveCell, LookIn:=xlFormulas, LookAt:= _
xlPart, SearchOrder:=xlByRows, SearchDirection:=xlNext
MatchCase:=False _
, SearchFormat:=False).Activate
txtBestellingArtikelOmschrijving2.Value = ActiveCell.Offset(0
1).Value

End Sub


what i want if it is possible that when the data is not found it wil
return a specific value to my second textbox.

can anybody help me

--
eyesonly196
-----------------------------------------------------------------------
eyesonly1965's Profile: http://www.excelforum.com/member.php...fo&userid=3419
View this thread: http://www.excelforum.com/showthread.php?threadid=54180

 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
Error: Value in Formula of wrong data type mak_nyce Excel Worksheet Functions 0 January 5th 10 06:04 PM
Help - error entering data into cell NEHicks Excel Worksheet Functions 0 October 2nd 09 04:59 PM
how do i add an error message if someone enters wrong data Mike Excel Discussion (Misc queries) 3 September 29th 09 03:30 PM
Error Message :A value used in the formula is of the wrong data ty Graham Excel Worksheet Functions 4 June 16th 09 03:51 PM
Entering a Formula / Wrong value John New Users to Excel 1 November 24th 07 05:04 PM


All times are GMT +1. The time now is 01:28 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"