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: 29
Default Comment help

I am taking the data from a userform to a comment on the cell the is
currently active. I am running into some errors using the following code
close to the end where the data is concantenated. What I need to do is a
carriage return....I thought that might be CHAR(10) within the comments area
so the outcome in the comments area might look something like this:

Customer name:
DOA:
CC#:
EXP Date:
Days Staying:

Current code:

Private Sub Submit_Click()

Dim res As VbMsgBoxResult

If Custname.Text = "" Then
MsgBox "Please enter a valid name!", vbOKOnly
End If

If CCNo.Text = "" Then
res = MsgBox(Prompt:="Do you want to enter a CC for the customer?", _
Buttons:=vbYesNo + vbQuestion)

If res = vbYes Then user.Custinfo.Show
End If


custnm = Custname.Text
dtoa = DOA.Value
CCN = CCNo.Value
ds = DOS.Value
EX = Exp.Value

com = "Customer name: " & custnm & CHAR(10) & "DOA: " & dtoa & CHAR(10) &
"CC#: " & CCN & _
"EXP Date: " & EX & CHAR(10) & "Days Staying: " & ds

End Sub

Thanks in advance!
--
EW - Analyst
 
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
copy comment content to cell content as data not as comment Lilach Excel Discussion (Misc queries) 2 June 21st 07 12:28 PM
How can I edit a comment w/o first having to select Show Comment Mary Ann Excel Discussion (Misc queries) 1 August 26th 05 12:34 AM
How do I insert a comment when the Insert:Comment menu is greyed? none Excel Discussion (Misc queries) 0 May 19th 05 12:36 AM
Comment Box Ann Sbaw Excel Discussion (Misc queries) 1 February 25th 05 09:35 PM
a comment plugin & copy paste directly from excel to comment ? fr. RFM Excel Worksheet Functions 0 December 1st 04 11:29 PM


All times are GMT +1. The time now is 01:32 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"