Formatting appSettings data using Expression Builder

G

Guest

Does anyone know if it's possible to format data stored in an appSetting node
when it's bound to a form control? I would like to format a date stored in
appSettings, and I bind to it as follows:

<asp:Label ID="SomeLabelID" Runat="Server" Text="<%$AppSettings:someDate %>"
/>
 
G

Guest

Hey,

Are you trying to achieve something like this?

<input type=text
value="<%=System.Configuration.ConfigurationSettings.AppSettings["fDate"].ToString()%>">
fDate is the key given in web.config.

Hope this would help u.

-Baskar BV-
 
G

Guest

That will definitely work, but I was hoping that I could use declarative
syntax like $AppSettings:fDate since it is much easier for our designers to
use that syntax instead of the full declaration.

BASKAR BV said:
Hey,

Are you trying to achieve something like this?

<input type=text
value="<%=System.Configuration.ConfigurationSettings.AppSettings["fDate"].ToString()%>">
fDate is the key given in web.config.

Hope this would help u.

-Baskar BV-

Darren Carter said:
Does anyone know if it's possible to format data stored in an appSetting node
when it's bound to a form control? I would like to format a date stored in
appSettings, and I bind to it as follows:

<asp:Label ID="SomeLabelID" Runat="Server" Text="<%$AppSettings:someDate %>"
/>
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
474,431
Messages
2,571,678
Members
48,796
Latest member
Greg L.

Latest Threads

Top