LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #8   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 6
Default Newbie with VBA for Excel

Hi there,

Thanks thanks for your help...

To see what this macro is all about, please follow this link :

http://www.good2know.freesurf.fr/startengtemp.html

And the complete macro :

Sub InsertRepresentativesInitials()
Dim ClasseurRep As Workbook
Dim Numdpt As String
Dim Colonne As Variant
Dim Initiales
Set ClasseurRep = GetObject("C:\TPExcel\Representants.xls")
Range("D4").Select
While ActiveCell.Value < ""
Numdpt = Left(ActiveCell.Value, 2)
Set Colonne =
ClasseurRep.Sheets(1).Range("A4:F20").Find(What:=N umdpt, _
LookIn:=xlFormulas, LookAt:=xlWhole).Address
Colonne = Range(Colonne).Column
Colonne = CInt(Colonne)
Initiales = ClasseurRep.Sheets(1).Cells(3,
Colonne).Comment.Text
ActiveCell.Offset(0, -1).Range("A1").Select
Wend
Set ClasseurRep = Nothing
Workbooks("clients.xls").Close
End Sub

And the not working line :

Set Colonne =
ClasseurRep.Sheets(1).Range("A4:F20").Find(What:=N umdpt, _
LookIn:=xlFormulas, LookAt:=xlWhole).Address

I have tried a few of your answers, maybe I have missed one or two,
but it still wouldn't work.

This macro is from a book about Excel and VBA 2003. I am learning the
basic of VBA programming from there.

Hope this can help you help me.

Cheers,
Pascal

 
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
Real Newbie newbie question Dave New Users to Excel 0 January 10th 07 07:55 PM
help for an excel newbie gingertips Excel Worksheet Functions 2 January 30th 06 06:55 PM
Please help an Excel Newbie! Mustangman New Users to Excel 1 December 27th 05 03:15 AM
Excel VBA Newbie Anauna Excel Programming 3 April 14th 05 10:42 PM
Newbie help...VBA w/ Excel Joe Excel Programming 3 August 11th 03 11:30 PM


All times are GMT +1. The time now is 02:09 AM.

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"