Showing posts with label case. Show all posts
Showing posts with label case. Show all posts

Wednesday, March 28, 2012

The bitwise combination of the DataControlRowState values

Hi,

I want to use the switch loop for the state of a gridrow:

switch (gvr.RowState)
{
case DataControlRowState.Selected:
case DataControlRowState.Alternate:
case DataControlRowState.Normal:
// doing something
break;
case DataControlRowState.Edit:
// doing something
break;
case DataControlRowState.Insert:
// doing something
break;
}

But because the row can be both selected and normal (bitwise combination), the rowstate is none of them. when I output the rowstate to the page it is for example "Selected, Normal". How can I add a case value for a bitwise combination?

KaaNThis will work:

case DataControlRowState.Selected | DataControlRowState.Normal:

The case of the crazy reseting dropdowns :-( Please help!

Hi everyone,

I keep getting a problem with dropdownlist controls. It sounds really stupid,
but my app is screwed as long as this keeps happening.

It seems to spontaneously happen and then I cant fix it without rebuilding
the whole page from scratch! Not Fun. :-(

So whats happening is I have my dropdowns on the page. The user comes along
and selects an option, but when the user submits the page,. its as if nothing
was changed.
The dropdowns all reset themselves to the default values. No modified value
reaches the server so its not just a view state thing (I think).

So basically, my dropdowns just dont work. Bear in mind, that these were
all working perfectly before. I then do some trivial work to the page - adding
controls and the like, and the whole thing just buggers up!

Can anyone think whats happening here? What would cause dropdown controls
to just stop sending their values and reset themselves?

If anyone at all has even the stupidist suggestion I would be so grateful
if you could tell me cos this is getting really serious. Its supposed to
be live now!

:-(

Thanks to anyone who can help

SimonSimon,
Do your dropdown controls have their AutoPostback property set to "true"?
This is required if you want a change by the user to cause a postback
and fire the SelectedIndexChanged event where you can handle the event.
Peter

--
Co-founder, Eggheadcafe.com developer portal:
http://www.eggheadcafe.com
UnBlog:
http://petesbloggerama.blogspot.com

"Simon Harvey" wrote:

> Hi everyone,
> I keep getting a problem with dropdownlist controls. It sounds really stupid,
> but my app is screwed as long as this keeps happening.
> It seems to spontaneously happen and then I cant fix it without rebuilding
> the whole page from scratch! Not Fun. :-(
> So whats happening is I have my dropdowns on the page. The user comes along
> and selects an option, but when the user submits the page,. its as if nothing
> was changed.
> The dropdowns all reset themselves to the default values. No modified value
> reaches the server so its not just a view state thing (I think).
> So basically, my dropdowns just dont work. Bear in mind, that these were
> all working perfectly before. I then do some trivial work to the page - adding
> controls and the like, and the whole thing just buggers up!
> Can anyone think whats happening here? What would cause dropdown controls
> to just stop sending their values and reset themselves?
> If anyone at all has even the stupidist suggestion I would be so grateful
> if you could tell me cos this is getting really serious. Its supposed to
> be live now!
> :-(
> Thanks to anyone who can help
> Simon
>
After the user submits the form, how are you getting the values from
the drop downs?

After the form is submitted does yourDropDown.SelectedValue = "" - or
the default value?

Have you tried Request.Form("youDropDown")? Does that still equal ""?

Can you reply back with some code for us?

Jeremy Reid
http://blackstaronline.net/hgtit
are you filling up your combobox each time the page loads? did you use "if
(!Page.IsPostBack)" is not, you should, it's probably your problem.

I hope it helps

ThunderMusic

"Simon Harvey" <nothanks@dotnet.itags.org.hotmail.com> wrote in message
news:94a1890869bf8c8038d5030666f@dotnet.itags.org.news.microsoft.co m...
> Hi everyone,
> I keep getting a problem with dropdownlist controls. It sounds really
> stupid, but my app is screwed as long as this keeps happening.
> It seems to spontaneously happen and then I cant fix it without rebuilding
> the whole page from scratch! Not Fun. :-(
> So whats happening is I have my dropdowns on the page. The user comes
> along and selects an option, but when the user submits the page,. its as
> if nothing was changed.
> The dropdowns all reset themselves to the default values. No modified
> value reaches the server so its not just a view state thing (I think).
> So basically, my dropdowns just dont work. Bear in mind, that these were
> all working perfectly before. I then do some trivial work to the page -
> adding controls and the like, and the whole thing just buggers up!
> Can anyone think whats happening here? What would cause dropdown controls
> to just stop sending their values and reset themselves?
> If anyone at all has even the stupidist suggestion I would be so grateful
> if you could tell me cos this is getting really serious. Its supposed to
> be live now!
> :-(
> Thanks to anyone who can help
> Simon

The case of the crazy reseting dropdowns :-( Please help!

Hi everyone,
I keep getting a problem with dropdownlist controls. It sounds really stupid
,
but my app is screwed as long as this keeps happening.
It seems to spontaneously happen and then I cant fix it without rebuilding
the whole page from scratch! Not Fun. :-(
So whats happening is I have my dropdowns on the page. The user comes along
and selects an option, but when the user submits the page,. its as if nothin
g
was changed.
The dropdowns all reset themselves to the default values. No modified value
reaches the server so its not just a view state thing (I think).
So basically, my dropdowns just dont work. Bear in mind, that these were
all working perfectly before. I then do some trivial work to the page - addi
ng
controls and the like, and the whole thing just buggers up!
Can anyone think whats happening here? What would cause dropdown controls
to just stop sending their values and reset themselves?
If anyone at all has even the stupidist suggestion I would be so grateful
if you could tell me cos this is getting really serious. Its supposed to
be live now!
:-(
Thanks to anyone who can help
SimonSimon,
Do your dropdown controls have their AutoPostback property set to "true"?
This is required if you want a change by the user to cause a postback
and fire the SelectedIndexChanged event where you can handle the event.
Peter
Co-founder, Eggheadcafe.com developer portal:
http://www.eggheadcafe.com
UnBlog:
http://petesbloggerama.blogspot.com
"Simon Harvey" wrote:

> Hi everyone,
> I keep getting a problem with dropdownlist controls. It sounds really stup
id,
> but my app is screwed as long as this keeps happening.
> It seems to spontaneously happen and then I cant fix it without rebuilding
> the whole page from scratch! Not Fun. :-(
> So whats happening is I have my dropdowns on the page. The user comes alon
g
> and selects an option, but when the user submits the page,. its as if noth
ing
> was changed.
> The dropdowns all reset themselves to the default values. No modified valu
e
> reaches the server so its not just a view state thing (I think).
> So basically, my dropdowns just dont work. Bear in mind, that these were
> all working perfectly before. I then do some trivial work to the page - ad
ding
> controls and the like, and the whole thing just buggers up!
> Can anyone think whats happening here? What would cause dropdown controls
> to just stop sending their values and reset themselves?
> If anyone at all has even the stupidist suggestion I would be so grateful
> if you could tell me cos this is getting really serious. Its supposed to
> be live now!
> :-(
> Thanks to anyone who can help
> Simon
>
>
After the user submits the form, how are you getting the values from
the drop downs?
After the form is submitted does yourDropDown.SelectedValue = "" - or
the default value?
Have you tried Request.Form("youDropDown")? Does that still equal ""?
Can you reply back with some code for us?
Jeremy Reid
http://blackstaronline.net/hgtit
are you filling up your combobox each time the page loads? did you use "if
(!Page.IsPostBack)" is not, you should, it's probably your problem.
I hope it helps
ThunderMusic
"Simon Harvey" <nothanks@dotnet.itags.org.hotmail.com> wrote in message
news:94a1890869bf8c8038d5030666f@dotnet.itags.org.news.microsoft.com...
> Hi everyone,
> I keep getting a problem with dropdownlist controls. It sounds really
> stupid, but my app is screwed as long as this keeps happening.
> It seems to spontaneously happen and then I cant fix it without rebuilding
> the whole page from scratch! Not Fun. :-(
> So whats happening is I have my dropdowns on the page. The user comes
> along and selects an option, but when the user submits the page,. its as
> if nothing was changed.
> The dropdowns all reset themselves to the default values. No modified
> value reaches the server so its not just a view state thing (I think).
> So basically, my dropdowns just dont work. Bear in mind, that these were
> all working perfectly before. I then do some trivial work to the page -
> adding controls and the like, and the whole thing just buggers up!
> Can anyone think whats happening here? What would cause dropdown controls
> to just stop sending their values and reset themselves?
> If anyone at all has even the stupidist suggestion I would be so grateful
> if you could tell me cos this is getting really serious. Its supposed to
> be live now!
> :-(
> Thanks to anyone who can help
> Simon
>

Tuesday, March 13, 2012

the membership of asp.net2.0 is useful in my case?

Membership is purely for authentication. For extra user data you should look
into the Profile.

-Brock
DevelopMentor
http://staff.develop.com/ballen

> the membership asp.net2.0I have many User attributes like telephone
> number,
> security ID, Country etc...
> I must retrive these attributes after the user login.
> How can I save do with the membership of asp.net2.0?Adding that I have yet to come to understand the scope of the current
aspnetdb.mdb database schema and hope somebody who knows what the heck all
those columns actually mean and what they can be used for will document it
and doing it yesterday will not be soon enough for me.

--
<%= Clinton Gallagher
METROmilwaukee "Regional Information Services"
NET csgallagher AT metromilwaukee.com
URL http://clintongallagher.metromilwaukee.com/

"Brock Allen" <ballen@.NOSPAMdevelop.com> wrote in message
news:453106632490060869625168@.msnews.microsoft.com ...
> Membership is purely for authentication. For extra user data you should
> look into the Profile.
> -Brock
> DevelopMentor
> http://staff.develop.com/ballen
>
>> the membership asp.net2.0I have many User attributes like telephone
>> number,
>> security ID, Country etc...
>> I must retrive these attributes after the user login.
>> How can I save do with the membership of asp.net2.0?
>>
Well, I'd agree. It'd be nice to have these documented, but on the other
hand that's somewhat going against the idea of a provider (wether it be membership
or profile). IOW, it's a black box of functionality. It's academically interesting
to understand them, but too much info is a bad thing as one tends to want
to modify things when you shouldn't. If you don't like their implementation,
you can create your own Membership or Profile provider that works with all
the UI controls just the same as the built in providers from Microsoft.

-Brock
DevelopMentor
http://staff.develop.com/ballen

> Adding that I have yet to come to understand the scope of the current
> aspnetdb.mdb database schema and hope somebody who knows what the heck
> all those columns actually mean and what they can be used for will
> document it and doing it yesterday will not be soon enough for me.
> "Brock Allen" <ballen@.NOSPAMdevelop.com> wrote in message
> news:453106632490060869625168@.msnews.microsoft.com ...
>> Membership is purely for authentication. For extra user data you
>> should look into the Profile.
>>
>> -Brock
>> DevelopMentor
>> http://staff.develop.com/ballen
>>> the membership asp.net2.0I have many User attributes like telephone
>>> number,
>>> security ID, Country etc...
>>> I must retrive these attributes after the user login.
>>> How can I save do with the membership of asp.net2.0?
Its not a matter of like or dislike. I can't dislike something simply
because I do not understand it. Its after I come to understand something
that I can make a reasonable determination.

I'm confident the schema will be documented and many articles will appear --
eventually -- but again, yesterday would not have been too soon for me.

Where is Dino Esposito et. el. when you really need them? ;-)

--
<%= Clinton Gallagher
METROmilwaukee "Regional Information Services"
NET csgallagher AT metromilwaukee.com
URL http://clintongallagher.metromilwaukee.com/

"Brock Allen" <ballen@.NOSPAMdevelop.com> wrote in message
news:460338632490389934897792@.msnews.microsoft.com ...
> Well, I'd agree. It'd be nice to have these documented, but on the other
> hand that's somewhat going against the idea of a provider (wether it be
> membership or profile). IOW, it's a black box of functionality. It's
> academically interesting to understand them, but too much info is a bad
> thing as one tends to want to modify things when you shouldn't. If you
> don't like their implementation, you can create your own Membership or
> Profile provider that works with all the UI controls just the same as the
> built in providers from Microsoft.
> -Brock
> DevelopMentor
> http://staff.develop.com/ballen
>
>> Adding that I have yet to come to understand the scope of the current
>> aspnetdb.mdb database schema and hope somebody who knows what the heck
>> all those columns actually mean and what they can be used for will
>> document it and doing it yesterday will not be soon enough for me.
>>
>> "Brock Allen" <ballen@.NOSPAMdevelop.com> wrote in message
>> news:453106632490060869625168@.msnews.microsoft.com ...
>>
>>> Membership is purely for authentication. For extra user data you
>>> should look into the Profile.
>>>
>>> -Brock
>>> DevelopMentor
>>> http://staff.develop.com/ballen
>>>> the membership asp.net2.0I have many User attributes like telephone
>>>> number,
>>>> security ID, Country etc...
>>>> I must retrive these attributes after the user login.
>>>> How can I save do with the membership of asp.net2.0?
Its not a matter of like or dislike. I can't dislike something simply
because I do not understand it. Its after I come to understand something
that I can make a reasonable determination.

I'm confident the schema will be documented and many articles will appear --
eventually -- but again, yesterday would not have been too soon for me.

Where is Dino Esposito et. el. when you really need them? ;-)

--
<%= Clinton Gallagher
METROmilwaukee "Regional Information Services"
NET csgallagher AT metromilwaukee.com
URL http://clintongallagher.metromilwaukee.com/

"Brock Allen" <ballen@.NOSPAMdevelop.com> wrote in message
news:460338632490389934897792@.msnews.microsoft.com ...
> Well, I'd agree. It'd be nice to have these documented, but on the other
> hand that's somewhat going against the idea of a provider (wether it be
> membership or profile). IOW, it's a black box of functionality. It's
> academically interesting to understand them, but too much info is a bad
> thing as one tends to want to modify things when you shouldn't. If you
> don't like their implementation, you can create your own Membership or
> Profile provider that works with all the UI controls just the same as the
> built in providers from Microsoft.
> -Brock
> DevelopMentor
> http://staff.develop.com/ballen
>
>> Adding that I have yet to come to understand the scope of the current
>> aspnetdb.mdb database schema and hope somebody who knows what the heck
>> all those columns actually mean and what they can be used for will
>> document it and doing it yesterday will not be soon enough for me.
>>
>> "Brock Allen" <ballen@.NOSPAMdevelop.com> wrote in message
>> news:453106632490060869625168@.msnews.microsoft.com ...
>>
>>> Membership is purely for authentication. For extra user data you
>>> should look into the Profile.
>>>
>>> -Brock
>>> DevelopMentor
>>> http://staff.develop.com/ballen
>>>> the membership asp.net2.0I have many User attributes like telephone
>>>> number,
>>>> security ID, Country etc...
>>>> I must retrive these attributes after the user login.
>>>> How can I save do with the membership of asp.net2.0?
Try creating a new project and use the SQLProvider instedd of the
AccessProvider. If you do so then all the tables would be created and you
could visibly see the schema in the Visual Studio IDE.

"clintonG" wrote:

> Its not a matter of like or dislike. I can't dislike something simply
> because I do not understand it. Its after I come to understand something
> that I can make a reasonable determination.
> I'm confident the schema will be documented and many articles will appear --
> eventually -- but again, yesterday would not have been too soon for me.
> Where is Dino Esposito et. el. when you really need them? ;-)
> --
> <%= Clinton Gallagher
> METROmilwaukee "Regional Information Services"
> NET csgallagher AT metromilwaukee.com
> URL http://clintongallagher.metromilwaukee.com/
>
> "Brock Allen" <ballen@.NOSPAMdevelop.com> wrote in message
> news:460338632490389934897792@.msnews.microsoft.com ...
> > Well, I'd agree. It'd be nice to have these documented, but on the other
> > hand that's somewhat going against the idea of a provider (wether it be
> > membership or profile). IOW, it's a black box of functionality. It's
> > academically interesting to understand them, but too much info is a bad
> > thing as one tends to want to modify things when you shouldn't. If you
> > don't like their implementation, you can create your own Membership or
> > Profile provider that works with all the UI controls just the same as the
> > built in providers from Microsoft.
> > -Brock
> > DevelopMentor
> > http://staff.develop.com/ballen
> >> Adding that I have yet to come to understand the scope of the current
> >> aspnetdb.mdb database schema and hope somebody who knows what the heck
> >> all those columns actually mean and what they can be used for will
> >> document it and doing it yesterday will not be soon enough for me.
> >>
> >> "Brock Allen" <ballen@.NOSPAMdevelop.com> wrote in message
> >> news:453106632490060869625168@.msnews.microsoft.com ...
> >>
> >>> Membership is purely for authentication. For extra user data you
> >>> should look into the Profile.
> >>>
> >>> -Brock
> >>> DevelopMentor
> >>> http://staff.develop.com/ballen
> >>>> the membership asp.net2.0I have many User attributes like telephone
> >>>> number,
> >>>> security ID, Country etc...
> >>>> I must retrive these attributes after the user login.
> >>>> How can I save do with the membership of asp.net2.0?
>

the membership of asp.net2.0 is useful in my case?

the membership asp.net2.0I have many User attributes like telephone number,
security ID, Country etc...
I must retrive these attributes after the user login.
How can I save do with the membership of asp.net2.0?Membership is purely for authentication. For extra user data you should look
into the Profile.
-Brock
DevelopMentor
http://staff.develop.com/ballen

> the membership asp.net2.0I have many User attributes like telephone
> number,
> security ID, Country etc...
> I must retrive these attributes after the user login.
> How can I save do with the membership of asp.net2.0?
>
Adding that I have yet to come to understand the scope of the current
aspnetdb.mdb database schema and hope somebody who knows what the heck all
those columns actually mean and what they can be used for will document it
and doing it yesterday will not be soon enough for me.
<%= Clinton Gallagher
METROmilwaukee "Regional Information Services"
NET csgallagher AT metromilwaukee.com
URL http://clintongallagher.metromilwaukee.com/
"Brock Allen" <ballen@.NOSPAMdevelop.com> wrote in message
news:453106632490060869625168@.msnews.microsoft.com...
> Membership is purely for authentication. For extra user data you should
> look into the Profile.
> -Brock
> DevelopMentor
> http://staff.develop.com/ballen
>
>
>
>
Well, I'd agree. It'd be nice to have these documented, but on the other
hand that's somewhat going against the idea of a provider (wether it be memb
ership
or profile). IOW, it's a black box of functionality. It's academically inter
esting
to understand them, but too much info is a bad thing as one tends to want
to modify things when you shouldn't. If you don't like their implementation,
you can create your own Membership or Profile provider that works with all
the UI controls just the same as the built in providers from Microsoft.
-Brock
DevelopMentor
http://staff.develop.com/ballen
> Adding that I have yet to come to understand the scope of the current
> aspnetdb.mdb database schema and hope somebody who knows what the heck
> all those columns actually mean and what they can be used for will
> document it and doing it yesterday will not be soon enough for me.
> "Brock Allen" <ballen@.NOSPAMdevelop.com> wrote in message
> news:453106632490060869625168@.msnews.microsoft.com...
>
Its not a matter of like or dislike. I can't dislike something simply
because I do not understand it. Its after I come to understand something
that I can make a reasonable determination.
I'm confident the schema will be documented and many articles will appear --
eventually -- but again, yesterday would not have been too soon for me.
Where is Dino Esposito et. el. when you really need them? ;-)
<%= Clinton Gallagher
METROmilwaukee "Regional Information Services"
NET csgallagher AT metromilwaukee.com
URL http://clintongallagher.metromilwaukee.com/
"Brock Allen" <ballen@.NOSPAMdevelop.com> wrote in message
news:460338632490389934897792@.msnews.microsoft.com...
> Well, I'd agree. It'd be nice to have these documented, but on the other
> hand that's somewhat going against the idea of a provider (wether it be
> membership or profile). IOW, it's a black box of functionality. It's
> academically interesting to understand them, but too much info is a bad
> thing as one tends to want to modify things when you shouldn't. If you
> don't like their implementation, you can create your own Membership or
> Profile provider that works with all the UI controls just the same as the
> built in providers from Microsoft.
> -Brock
> DevelopMentor
> http://staff.develop.com/ballen
>
>
>
>
Try creating a new project and use the SQLProvider instedd of the
AccessProvider. If you do so then all the tables would be created and you
could visibly see the schema in the Visual Studio IDE.
"clintonG" wrote:

> Its not a matter of like or dislike. I can't dislike something simply
> because I do not understand it. Its after I come to understand something
> that I can make a reasonable determination.
> I'm confident the schema will be documented and many articles will appear
--
> eventually -- but again, yesterday would not have been too soon for me.
> Where is Dino Esposito et. el. when you really need them? ;-)
> --
> <%= Clinton Gallagher
> METROmilwaukee "Regional Information Services"
> NET csgallagher AT metromilwaukee.com
> URL http://clintongallagher.metromilwaukee.com/
>
> "Brock Allen" <ballen@.NOSPAMdevelop.com> wrote in message
> news:460338632490389934897792@.msnews.microsoft.com...
>
>