Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

css problem

0 views
Skip to first unread message

CreativeMind

unread,
Apr 28, 2008, 9:41:31 AM4/28/08
to
<style>
.Admin{
display: <%if( Convert.ToInt32(userType) !=1)?%>"inline"<%:%>"none"
}
</style>
please correct the syntax.
thx

George Ter-Saakov

unread,
Apr 28, 2008, 9:57:14 AM4/28/08
to
Are you using VB or C#?

Cause you kind of mixing both....
I do not know VB very well but I think there is no such construction like

if( Convert.ToInt32(userType) !=1)?

in C# it's (notice no IF)
(logical statement)?opertaotr:operator;

So it should be
(Convert.ToInt32(userType)
!=1)?Response.Write("inline"):Response.Write("none");

Not sure if inline (like below) code will work though
<%( Convert.ToInt32(userType) !=1)?%>"inline"<%:%>"none"<%;%>"

George

"CreativeMind" <aftab...@gmail.com> wrote in message
news:862bfa45-478b-409c...@y21g2000hsf.googlegroups.com...

CreativeMind

unread,
Apr 28, 2008, 11:44:47 AM4/28/08
to
thx..i solved it.

On Apr 28, 6:57 pm, "George Ter-Saakov" <gt-...@cardone.com> wrote:
> Are you using VB or C#?
>
> Cause you kind of mixing both....
> I do not know VB very well but I think there is no such construction like
>
> if( Convert.ToInt32(userType) !=1)?
>
> in C# it's (notice no IF)
> (logical statement)?opertaotr:operator;
>
> So it should be
> (Convert.ToInt32(userType)
> !=1)?Response.Write("inline"):Response.Write("none");
>
> Not sure if inline (like below) code will work though
> <%( Convert.ToInt32(userType) !=1)?%>"inline"<%:%>"none"<%;%>"
>
> George
>
> "CreativeMind" <aftab.pu...@gmail.com> wrote in message
0 new messages