[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

microsoft.public.dotnet.framework.aspnet.buildingcontrols

Custom webcontrol with reference to another one

iontichy

1/18/2007 8:18:00 PM

Hi,
I've been working on a custom webcontrol with a property that
references another webcontrol from the same page.
In my special test case I have a Person_firstname1 control and a
PersonSource1 control. The Person_firstname1 have a property of the
type PersonSource. Now i want to assign the this property in the visual
studio designer. How could I persuade the designer, to show a dropdown
list of the controls in the page with the correct type (e.g.
PersonSource1, PersonSource2 etc.)

Thanks in advance,
Mirko

9 Answers

Nathaniel Greene

1/20/2007 6:44:00 AM

0

Hello,
You would want to use the
IDReferenceProperty attribute
Seee the below code.
I created 2 classes - MailLink and ToLink. for ToLink there is a property
called Buddy that can be any MailLink. By attachign this attribute and
specifying the type then it will automagically enumerate these for you.

MailLink gBuddy;
[Browsable(true), IDReferenceProperty(typeof(MailLink))]
public MailLink Buddy
{
get { return gBuddy; }
set { gBuddy = value; }
}



"iontichy" wrote:

> Hi,
> I've been working on a custom webcontrol with a property that
> references another webcontrol from the same page.
> In my special test case I have a Person_firstname1 control and a
> PersonSource1 control. The Person_firstname1 have a property of the
> type PersonSource. Now i want to assign the this property in the visual
> studio designer. How could I persuade the designer, to show a dropdown
> list of the controls in the page with the correct type (e.g.
> PersonSource1, PersonSource2 etc.)
>
> Thanks in advance,
> Mirko
>
>

Reiko

12/18/2008 7:47:00 PM

0

On Dec 18, 11:00 am, Jim Aikin <midigur...@gmail.com> wrote:
> (snip)
> Just out of curiosity, if you didn't ask her about herself, what _did_
> you ask her about? Paris? The accordionist? The waiter?

(To jump in here a bit...) I asked her about herself no problem, but
then I asked her about several other things and got little to no
response. For the rest of the game, I didn't bother talking to her at
all. I don't know if I asked her about the wrong things, but aside
from the very beginning of the game, I had trouble getting more than a
couple sentences out of her. I don't remember exactly, but I think I
asked her about lunch, food, the accordionist, maybe the waiter or the
dog. I had trouble finding the right things to ask the old man, too.

~Reiko

Jim Aikin

12/18/2008 8:50:00 PM

0

Thanks for the feedback. I implemented some nonstandard commands
('invite her to join me for lunch' was one of them, I seem to recall),
but I could have done more with the standard set of topics to guide the
player in the right direction! This is, I think, an aspect of what Emily
was talking about elsewhere in this thread.

--JA

Reiko wrote:
> On Dec 18, 11:00 am, Jim Aikin <midigur...@gmail.com> wrote:
>> (snip)
>> Just out of curiosity, if you didn't ask her about herself, what _did_
>> you ask her about? Paris? The accordionist? The waiter?
>
> (To jump in here a bit...) I asked her about herself no problem, but
> then I asked her about several other things and got little to no
> response. For the rest of the game, I didn't bother talking to her at
> all. I don't know if I asked her about the wrong things, but aside
> from the very beginning of the game, I had trouble getting more than a
> couple sentences out of her. I don't remember exactly, but I think I
> asked her about lunch, food, the accordionist, maybe the waiter or the
> dog. I had trouble finding the right things to ask the old man, too.
>
> ~Reiko

goldfarb

12/19/2008 10:55:00 AM

0

In article <gidvit$25l$1@news.motzarella.org>,
Jim Aikin <midiguru23@gmail.com> wrote:
>David Goldfarb wrote:
>> When I played "April in Paris", it didn't occur to me to ASK WOMAN
>> ABOUT WOMAN until quite a while after I first encountered her.
>
>Just out of curiosity, if you didn't ask her about herself, what _did_
>you ask her about? Paris? The accordionist? The waiter?

I do recall asking her about the waiter; beyond that I can't really say.

--
David Goldfarb | "Questions are a burden to others.
goldfarb@ocf.berkeley.edu | Answers are a prison for oneself."
goldfarb@csua.berkeley.edu | -- _The Prisoner_, "Dance of the Dead"

Victor Gijsbers

12/19/2008 11:53:00 AM

0

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Jim Aikin wrote:
> Emily Short wrote:
>> On Dec 16, 7:53 am, Victor Gijsbers <vic...@lilith.gotdns.org> wrote:
>>>
>>> Obviously, once you have chosen, you cannot initiate the conversation
>>> again and choose the other options. You cannot mow the lawn. (You might
>>> mow the lawn by saving and restoring a couple of times, but if your
>>> choices have effects later in the game, not even this strategy will
>>> work.)
>
> Two points. First, saving and restoring (which are annoying jobs, and
> pull the player out of the story) WILL always work. I can save five
> versions of a scene with different names and then try out all of the
> conversation options.

Of course, but at some point that becomes equal to playing the game an
indefinite number of times, which is not a practical possibility.

If the game starts by giving you the choice between A and B, and you
choice has a profound effect in the final scene, then the only way to
see both in action is to play the entire game twice. You can do that, of
course; but it is not what we would normally call lawn-mowing. It is
playing the game twice.


> Second, speaking only for myself, I purely hate it when some of the
> conversation topics disappear from the menu. It pisses me off, because
> it prevents me from discovering stuff that might indeed be useful (or
> preferable to the stuff I _did_ discover). If a conversation menu is
> present, I need to be able to UNDO in order to rev up the lawn mower. If
> I can't at least UNDO and try other conversational branches, I will stop
> playing your game.

I'm not sure what you are saying. Are you saying that you don't want to
feel the reality of choice when you are reading interactive fiction?
That you never want to be confronted with a situation in which you must
choose either A or B, where this choice has profound effects on later
situations in the game?

If the whole _point_ of the conversation were the choice between A and
B, then how could it ever be the case that one choice would be "useful"
or "preferable" to the other, without you knowing this?

(I am obviously not talking about puzzle-based games where you might
miss out on crucial information by choosing the wrong conversation
option. That would be a very lame design indeed.)

Regards,
Victor
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail....

iEYEARECAAYFAklLixIACgkQoiOrMwvIZLzK1gCfTihaHEFari9ubDzSiE582/6F
+rYAoIbZYlePqOcbUUzuT0vkQbGSTP5s
=wpA1
-----END PGP SIGNATURE-----

Victor Gijsbers

12/19/2008 11:56:00 AM

0

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Conrad wrote:

> In other words, the desire to lawnmower reflects that the player,
> having made the choice, has a greater residual emotional investment in
> the choices unmade, and an insufficient investment in learning the
> outcome of the choice made. The solution to that is not in the
> interface, but in building investment and suspense and encouraging
> exploration leading up to the opportunity to make the decision: so
> that the player's mind has rehearsed several times the chosen option
> and is engaged with and invested in that contingency.

This is very true indeed.

Kind regards,
Victor
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail....

iEYEARECAAYFAklLi+AACgkQoiOrMwvIZLxnfQCfWXkoP8Op7NwFKZpxJ88BW3sp
LUYAnA40MqPXj8l2JLPcri0oOkGulUaf
=C1TF
-----END PGP SIGNATURE-----

steve.breslin

12/19/2008 6:59:00 PM

0

Conrad wrote:

> I don't think choice-points should
> be designed as points, but as webs.

Yes indeed. The "false problem" that Victor identifies ("the lawnmower
problem does not exist") is only a problem if the story design is
simplistic and disengaging -- in other words, if the designer handles
the concept of player choice clumsily.

In order for the choice to be significant, the writer needs to do so
much set-up (and implement both consequences sufficiently) that I
would recommend extremely few choices per game. Indeed, if you're
thematizing or featuring choice, rather than faking it, then you might
be best served by implementing one significant choice per game. The
design has to start with that, and select and develop the story, and
select and develop the interface, based on the effect that you want to
produce by that central choice.

> Usually, in reality, we do not
> face an on-rails experience until we get to a certain point, at which
> moment we can toggle ourselves onto one of a number of paths; and so
> virtual experiences predicated on that model seem unnatural to us.

Right, but it's not only unnatural, but oversimplified and trivial,
aesthetically lacking.

> In other words, the desire to lawnmower reflects that the player,
> having made the choice, has a greater residual emotional investment in
> the choices unmade, and an insufficient investment in learning the
> outcome of the choice made. The solution to that is not in the
> interface, but in building investment[.]

Precisely, or to put it differently, the solution is good writing and
design. The perceived problem is a problem in the writing/design, not
the presentation model.

I wrote upthread that the perceived liabilities of the ask/tell model
are actually productive resources in the hands of a capable writer/
designer. Indeed, I'm not sure why one would want to approach this as
a good/bad discussion (which leads to entrenchment and overstatement:
"as a player, I personally do not like X model," etc.), rather than a
comparison of the strengths of the different models.

A little background on why the old garde is resistant to this
seemingly obvious idea. (Apart from the obvious problem that standard
practice tends to petrify.)

Emily Short's recent efforts to document writing process are one of
the most important efforts in contemporary IF study. She is leading
away from tools-oriented development, towards concept-oriented
development. Emily Short makes a rigid and simple distinction between
choice-points and exposition not because she is unaware of the
potential complexity of the presentation (false choice-points designed
for exposition, degrees of agency/choice, etc.).

But going back to process, perhaps this is rooted in a thinking in
terms of implementation rather than design and presentation (so, a
choice-point makes changes to game state, whereas an exposition-point
does not). I would advocate putting the design/presentation first (so,
figure out what effect you want to produce), then figure out how to
carry this off procedurally; filling out a procedure with witty
dialogue is going to lead to an improvised effect which runs several
risks which have to be carefully avoided -- hence, stilted opinions on
what works.

Andrew Plotkin has long ago developed an interesting theory on the
aesthetic significance of the IF interface (compared with CYOA/menu
systems). In a nutshell, the open interface is misleading, because at
any given point there are only a limited number of successful commands
possible (and in most cases, one could menu-ize them). The critical
point is that this misleading-ness of the interface is aesthetically
productive: the "tell me anything"-style command interface engenders a
sense of freedom while at the same time quietly limits things, keeping
things manageable for the writer/designer. Without implying any
favoritism, this is a good account of the aesthetic effect of the
interface. It's a good *descriptive* theory.

Whether (and how) this applies to menu-based conversation, it's a
subtly but significantly different discussion. In such cases it's
probably going to be a less-than-brilliant effort if one begins by
trying to apply an old theory to a new discussion, rather than
consider the matter itself and develop a new theory as appropriate. An
interesting descriptive theory misapplied can quickly turn into a
misleading *prescriptive* theory.

kevindc1976

12/22/2008 3:54:00 PM

0

On Dec 19, 7:52 pm, Victor Gijsbers <vic...@lilith.gotdns.org> wrote:
> > Second, speaking only for myself, I purely hate it when some of the
> > conversation topics disappear from the menu. It pisses me off, because
> > it prevents me from discovering stuff that might indeed be useful (or
> > preferable to the stuff I _did_ discover). If a conversation menu is
> > present, I need to be able to UNDO in order to rev up the lawn mower. If
> > I can't at least UNDO and try other conversational branches, I will stop
> > playing your game.
>
> I'm not sure what you are saying. Are you saying that you don't want to
> feel the reality of choice when you are reading interactive fiction?
> That you never want to be confronted with a situation in which you must
> choose either A or B, where this choice has profound effects on later
> situations in the game?
>
> If the whole _point_ of the conversation were the choice between A and
> B, then how could it ever be the case that one choice would be "useful"
> or "preferable" to the other, without you knowing this?

(Pardon the random lurker jumping in on this very interesting
conversation...)

I think the frustration Jim is expressing is not at being confronted
with a meaningful A-B choice, but rather the phenomenon in some poorly
implemented menu-conversation games where you've got a menu of several
not obviously mutually exclusive questions, such as in the following
hypothetical transcript:

> TALK TO NEIGHBOR

"Hi Bob," you say, waving to your neighbor of 10 years, standing on
the other side of the white picket fence.

"Hello Fred," he replies with a smile.

1. "So, how are the wife and kids?"
2. "Did you catch that ballgame last night?"
3. "Have you heard anything about the new neighbors down the block?"
4. "Is that a new barbecue you've got there?"
5. "It sure is hot today."
6. "How's that new plasma TV working out for you?"

> 1

Bob sighs, "Same as ever. Billy got into another fight at school, and
somehow Helen thinks it's my fault."

1. "Did you catch that ballgame last night?"
2. "Have you heard anything about the new neighbors down the block?"
3. "Is that a new barbecue you've got there?"
4. "It sure is hot today."
5. "How's that new plasma TV working out for you?"

> 1

"Yeah," Bob says, "that was an amazing catch, wasn't it? Hey, speaking
of ballgames, do you want to join us tonight to watch the playoffs?"

1. "Sure, I can't wait to check out your new TV. I'll bring over my
famous nachos."
2. "Sorry, my wife would kill me... tonight's our anniversary."

> 1

"Great! See you at 7:00." Bob says before turning and going back into
his house.

Nothing about the first menu suggests that this is an exclusive or
limited choice and that you should carefully consider which piece(s)
of information would be most preferable and useful. So, despite the
fact that you might be most interested in the gossip on the new
neighbors, if you decide to engage in a little too much innocuous
smalltalk first, it's incredibly annoying that you're penalized for
this by being denied the information you really wanted.

It also occurs to me that the menu in the above transcript is a
perfect example of what produces the "lawnmower" behavior -- and no,
it's not the suburban setting. :)

Such a menu effectively tells the player that at this point there are
six and only six different pieces of information that Bob will
provide. The natural inclination of your typical IF-player is to then
try collect all this information. Most end up mechanically doing so by
running through all the numbers, which is very boring, and makes the
NPC feel very static/flat/robotic/etc. Somehow blaming this on lazy
players, who should make more thoughtful menu selections to generate a
more spontaneous life-like conversation is ridiculous. (*Note: I am
not at all suggesting that Victor is taking such an extreme position.)
The menu system all but begs the player to run through all the
options. What sane player would deliberately NOT ask a known, valid
question and thereby pass up some potentially interesting and/or
essential information, simply because it would not have otherwise
occurred to the player to ask it had it not been on the menu?

I think the distinction brought up earlier by Emily between "choice-
conversation" and "exploratory/exposition-conversation" is important,
though. These two very different types of conversations (or stages in
a conversation) are served very differently by the two conversation
systems (i.e. menus are good for choice, and ask/tell is good for
exposition), and a lot of times supporters of each system end up
arguing past one another because they're trying to implement
completely different types of conversations.

Personally, I think the greatest promise/flexibility is with the
hybrid-style in TADS 3, which allows the author to seamlessly
integrate menu-like options into appropriate points in an otherwise
ask/tell conversation, or with the similar ask/tell with
disambiguation which Emily and others have described.

Blank

1/5/2009 4:22:00 PM

0

Jim Aikin wrote:
> Emily Short wrote:
>> On Dec 16, 7:53 am, Victor Gijsbers <vic...@lilith.gotdns.org> wrote:
>>>
>>> Obviously, once you have chosen, you cannot initiate the conversation
>>> again and choose the other options. You cannot mow the lawn. (You might
>>> mow the lawn by saving and restoring a couple of times, but if your
>>> choices have effects later in the game, not even this strategy will
>>> work.)
>
> Two points. First, saving and restoring (which are annoying jobs, and
> pull the player out of the story) WILL always work. I can save five
> versions of a scene with different names and then try out all of the
> conversation options.
>
> Second, speaking only for myself, I purely hate it when some of the
> conversation topics disappear from the menu. It pisses me off, because
> it prevents me from discovering stuff that might indeed be useful (or
> preferable to the stuff I _did_ discover). If a conversation menu is
> present, I need to be able to UNDO in order to rev up the lawn mower. If
> I can't at least UNDO and try other conversational branches, I will stop
> playing your game.
>

To me that feels very odd, as though you're trying to spread the
consciousness of your avatar out "sideways" through the game-world skein
of possibilities so that you always make the best choice available. Sort
of like a cheat "God mode" (am I making sense?)

When I'm playing a game, I'm interested in experiencing one story-line
completely. Assuming that the author has demonstrated competence in
writing IF, I'm willing to trust that any one of the two or three
exclusive choices presented to me is equally significant. (This is
usually the real problem: having three equally valid choices cumulates
to a *lot* of work unless the effects are trivial.)

For me the mechanical overhead of menu based systems is the need to note
down what I've done so that I can make consciously different choices on
subsequent playthroughs. I find myself yearning for a LOOPBACK
after-death option, where RESTART puts you back at the beginning as
though playing the game for the first time, whereas LOOPBACK puts me
back at the beginning - but the game knows what I did before, so that it
could, for example, mark choices that I'd followed before, or offer
special commands to skip sections I'd completely solved the first time.

--jz



>> The matching problem with ASK/TELL is that the player doesn't see a
>> list of options, therefore may get stuck on guess-the-noun problems
>> (what should I ask about? how do I phrase it?), or may not find out
>> critical pieces of information because he never knew to ask about
>> them.
>
> A context-sensitive 'topics' command addresses this issue. It allows the
> player to "peek" at the hidden menu without implying that the list of
> topics provided is necessarily complete (which it shouldn't be).
>
>> a) for the player to be guaranteed contact with all conversation
>> information in the game that he absolutely needs to know -- whether he
>> needs it to solve a puzzle or to make a moral choice (no guess-the-
>> noun, no stuckness);
>
> I'm not sure that doesn't imply "writing down" to the most obtuse player
> imaginable. Perhaps I'm being alarmist. I can see the value of the
> principle, to be sure.
>
>> Underneath that level there also needs to be (in my opinion) another
>> level of modeling entirely. This level directs the flow of
>> conversation by prompting the NPC to bring up important topics when
>> the player has missed them; it moves the conversation along when a
>> given branch has dried up; it may provide selective hinting to the
>> player about what the player character is considering saying next,
>> without meaning that those options are the only ones available.
>
> I really like this approach, in theory. I've never had the courage to
> tackle it in one of my own games, but I think it's the best way to
> handle things. Technical question: In T3, one might write AgendaItems
> for the NPC. Is there an equivalent in I7?
>
> I guess an AgendaItem is sort of like a daemon, but it has some widgets
> that turn it on and then off automatically in response to simple
> conditional tests. An "every turn when Conversations With Joyce is
> happening" rule might be able to produce the same result(s), but it
> would put all of Joyce's agenda items in one big lump of code rather
> than packeting them in OO fashion.
>
> --JA