Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Checking data with a loop

Hi,

I'm not the best programmer in the world and I'm in need of help. I wa
trying to make a loop

Sub macro2()
Dim Nummer As String

Worksheets("Sheet1").Activate
Do Until Nummer 0
Nummer = Application.InputBox("Doe eens een nummer"
"Selecteren", Type:=2)
Exit Do
Loop
Range("B12").Select
With Selection.Font
.Name = "Arial"
.Size = Nummer
.Strikethrough = False
.Superscript = False
.Subscript = False
.OutlineFont = False
.Shadow = False
.Underline = xlUnderlineStyleNone
.ColorIndex = xlAutomatic
End With

End Sub


But it did not work. I tried to check the input but it failed. And ho
do I set borders (input between 10 and 30 (for example)

Tnxs in advanced

--
Message posted from http://www.ExcelForum.com

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,272
Default Checking data with a loop

Try this alternate

Sub macro2()
Dim Nummer As Integer

Worksheets("Sheet1").Activate

Do Until Nummer 0
Nummer = Application.InputBox("Doe eens een nummer", "Selecteren",
Type:=2)
Loop

With Range("B12").Font
.Name = "Arial"
.Size = Nummer
End With

End Sub


--

HTH

Bob Phillips
... looking out across Poole Harbour to the Purbecks
(remove nothere from the email address if mailing direct)

"Syrus the Virus " wrote in
message ...
Hi,

I'm not the best programmer in the world and I'm in need of help. I was
trying to make a loop

Sub macro2()
Dim Nummer As String

Worksheets("Sheet1").Activate
Do Until Nummer 0
Nummer = Application.InputBox("Doe eens een nummer",
"Selecteren", Type:=2)
Exit Do
Loop
Range("B12").Select
With Selection.Font
Name = "Arial"
Size = Nummer
Strikethrough = False
Superscript = False
Subscript = False
OutlineFont = False
Shadow = False
Underline = xlUnderlineStyleNone
ColorIndex = xlAutomatic
End With

End Sub


But it did not work. I tried to check the input but it failed. And how
do I set borders (input between 10 and 30 (for example)

Tnxs in advanced.


---
Message posted from http://www.ExcelForum.com/



Reply
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
Spell Checking with checking cell notes jfitzpat Excel Discussion (Misc queries) 0 August 8th 07 10:26 PM
Checking Data in 2 spreadsheets Paul Sheppard Excel Discussion (Misc queries) 0 May 31st 06 08:22 AM
Checking for data duplications Nikki Excel Discussion (Misc queries) 1 March 2nd 06 04:07 PM
Please HELP: Checking data guy Excel Worksheet Functions 3 December 5th 05 02:51 AM
Checking if a cell is filled up with data xpucto Excel Discussion (Misc queries) 1 May 26th 05 10:17 AM


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

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

About Us

"It's about Microsoft Excel"