The first one works.
Haven't tried the second one.
Wasn't aware of '$conn.Opened().
But it's good to know
On Thu, 2012-08-09 at 12:51 +0930, Adam Ant wrote:
> On Thu, Aug 9, 2012 at 12:35 PM, rocko wrote:
> > Ok if I replace the 'Else If' with an 'Else'
> > I get an error:
> > Else without If.
>
On Thu, Aug 9, 2012 at 12:35 PM, rocko wrote:
> Ok if I replace the 'Else If' with an 'Else'
> I get an error:
> Else without If.
> But there is an 'If' after the 'Try'.
> unless you can't put an 'Else' after an 'Try...If'
Ah! No you can't use
Try If blahblahblah
(and there are some other thi
Ok if I replace the 'Else If' with an 'Else'
I get an error:
Else without If.
But there is an 'If' after the 'Try'.
unless you can't put an 'Else' after an 'Try...If'
On Thu, 2012-08-09 at 12:25 +0930, Adam Ant wrote:
> On Thu, Aug 9, 2012 at 11:23 AM, rocko wrote:
> > Trying to get a message.in
On Thu, Aug 9, 2012 at 11:23 AM, rocko wrote:
> Trying to get a message.info to display when a successful connection
> to a database is made.
> Tried using an 'Else If' after a 'Try $hConn.Open' statement
> but that gives an error.
> So tried a simple 'If' but I'm not sure how the syntax should be
Trying to get a message.info to display when a successful connection
to a database is made.
Tried using an 'Else If' after a 'Try $hConn.Open' statement
but that gives an error.
So tried a simple 'If' but I'm not sure how the syntax should be.
CODE:
Try $hConn.Open
If Error Then Print "Database