VDBSET in Visual Basic
In an input dialog, users can specify a value, or a value prefixed by a
writeback command. The script writes the value to the database with weighted
allocation (the default) or as specified by the writeback command.
Sub splash_demo ()
Dim strValue
Dim varReturnValue
Dim varWriteback
strValue = InputBox("Input", "Enter a value to be splashed or a
splasher operation!")
If Left (StrValue, 1) = "#" Or Left (StrValue, 1)="&" or ...Then
'Splasher operation!
varWriteback = strValue
Else 'simple value entered!
varWriteback = Val(strValue)
End if
varReturnValue = Application.Run ("Splasher.xla!VDBSET",_
varWriteback,_
"LOCAL/Tutor_EN",_
"Totsales",_
"2006",_
"Budget",_
"European Union",_
"Total Servers",_
"January",_
"Units")
End Sub