EQ2Interface

EQ2Interface (https://www.eq2interface.com/forums/index.php)
-   UI Developer Discussion (https://www.eq2interface.com/forums/forumdisplay.php?f=3)
-   -   Datasource Container (https://www.eq2interface.com/forums/showthread.php?t=15545)

TalTal 03-30-2011 07:37 AM

Datasource Container
 
Is it possible to dynamically alter the data inside a datasource?

<DataSource Name="PosItemsDS">
<Data Name="1" text="Parent.Parent.Item01.Descrip" />
<Data Name="2" text="B" />
</DataSource>

<Button Name="" Size="0,0" OnPress="
Parent.PosItemsDS.1.text=Parent.Parent.Item01.Descrip
"/>

This does not appear to work. I have also tried:

<Button Name="" Size="0,0" OnPress="
PosItemsDS.1.text=Parent.Parent.Item01.Descrip
"/>

this does not work either. Is it impossible or am I missing something?

Silat

Drumstix42 03-30-2011 11:57 AM

Not sure why, but you can add Data objects to just a plain page. Unless you really need the Datasource for something?

Landiin 03-30-2011 01:39 PM

if I recall you can not directly access the info in a DataSource object. You can add a data object to a page object and access but not from within aq DataSource object.

TalTal 03-30-2011 06:56 PM

Quote:

Originally Posted by Drumstix42 (Post 96519)
Not sure why, but you can add Data objects to just a plain page. Unless you really need the Datasource for something?

Quote:

Originally Posted by Landiin (Post 96520)
if I recall you can not directly access the info in a DataSource object. You can add a data object to a page object and access but not from within aq DataSource object.

So if I understand you correctly:

<Page>
<data>
<data>
<data>
</Page>

works. Can it feed a dropdown....that is what i was using the datasource for.

Silat

gm9 03-31-2011 04:54 AM

Just confirming that you cannot manipulate DataSource objects dynamically. As far as I know they are treated as a list and never added into the XML tree at all (or if they are they would be enumerated differently, since a DataSource can contain many same-named Data items and thus the name could not be used to address them).

You also cannot use a Page as a DataSource.

What you can do, however, is to use several predefined DataSources and switch them out dynamically.

TalTal 03-31-2011 09:40 AM

Quote:

Originally Posted by gm9 (Post 96535)
Just confirming that you cannot manipulate DataSource objects dynamically. As far as I know they are treated as a list and never added into the XML tree at all (or if they are they would be enumerated differently, since a DataSource can contain many same-named Data items and thus the name could not be used to address them).

You also cannot use a Page as a DataSource.

What you can do, however, is to use several predefined DataSources and switch them out dynamically.

lol. Everytime I try to figure out a way to make the things I do more dynamic the darn ui limits me. Thanks for the info!

Silat

Drumstix42 03-31-2011 01:14 PM

Welcome the EQ2 interface TalTal! :nana:

sarcasm alert

Landiin 03-31-2011 01:16 PM

Quote:

Originally Posted by TalTal (Post 96538)
lol. Everytime I try to figure out a way to make the things I do more dynamic the darn ui limits me. Thanks for the info!

Silat

Yup, is why I hardly bother adding neet little things to extreme. I've grown tired of jumping through hoops. Every now and thin I'll get a bug and add something. Mostly when I am an work and bored though lol.


All times are GMT -5. The time now is 10:10 PM.

vBulletin® - Copyright ©2000 - 2026, Jelsoft Enterprises Ltd.
© MMOUI