473,657 Members | 2,771 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Data type for a block of text?

Hey all, I'm coming from the ColdFusion world and am pretty new to .Net2. My
issue is, I've got a page where the content (with html formatting included)
is stored in a db table field. In MS Access, the field type was Memo, in
SSExpress I'm using nvarchar(max).

When I try to display the contents/paragraphs in my aspx page (using
Gridview) , I see all the html coding & formatting characters.

Am I using the right data type? Should I be using something other than
GridView? Am I even in the right forum for this question?

Also, I'm trying to find a listing of default value & binding functions like
"GetDate()" Any links?

Thanks in advance!
Sep 13 '07 #1
1 1251
You are going to have to take control of this. Most likely, you are using an
AccessDataSourc e control? If so, the actually data is stored as XML, which
will escape the <, and a few other characters, to conform to XML standards.
If you actually view source, you probably see this

&lt;H1&gt;My Header&lt;/H1&gt;

instead of this

<H1>My header</H1>

You may do better with a DataReader and binding the data to the controls
yourself, rather than using the "auto binding" in .NET.

--
Gregory A. Beamer
MVP, MCP: +I, SE, SD, DBA

*************** *************** *************** ****
| Think outside the box!
|
*************** *************** *************** ****
"Chris G." <Ch****@discuss ions.microsoft. comwrote in message
news:93******** *************** ***********@mic rosoft.com...
Hey all, I'm coming from the ColdFusion world and am pretty new to .Net2.
My
issue is, I've got a page where the content (with html formatting
included)
is stored in a db table field. In MS Access, the field type was Memo, in
SSExpress I'm using nvarchar(max).

When I try to display the contents/paragraphs in my aspx page (using
Gridview) , I see all the html coding & formatting characters.

Am I using the right data type? Should I be using something other than
GridView? Am I even in the right forum for this question?

Also, I'm trying to find a listing of default value & binding functions
like
"GetDate()" Any links?

Thanks in advance!

Sep 13 '07 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
3077
by: Citoyen du Monde | last post by:
Trying to get some ideas on a simple javascript project (to teach myself the language). I want to develop a client-side vocabulary practice application that would allow users to enter their own words, their own definitions plus an example of how the word is used in practice. It'll be all client side with - cookies? to get persistence so that the words won't disappear on me each time the page is closed (which is what happened when I
5
8328
by: javaguy | last post by:
I have a data entry web application that is formatted heavily with tables. Having learned a bit of CSS, I'm hoping to rewrite this using <div> tags. But I have run into a formatting problem that keeps me from a solution. I'm hoping for some trick. Assume that "label_a" is a <label> tag and "INPUT_A" is an <input> tag. A sample of my current web page is: <table> <tr><td>label_a</td><td>INPUT_A</td>
9
1673
by: gov | last post by:
Hi, I've just started to learn programming and was told this was a good place to ask questions :) Where I work, we receive large quantities of data which is currently all printed on large, obsolete, dot matrix printers. This is a problem because the replacement parts will not be available for much longer. So I'm trying to create a program which will capture the fixed width
10
2896
by: Noozer | last post by:
Below is some ASP, HTML and javascript. It is part of a page used to maintain a small database. This code did work at one time, but has since stopped. For some reason the data on my form is not being passed to the page specified in the Action property of the form. This is on a Windows 2000 Pro PC. I copied the code to another server (Windows XP Pro machine) and it DOES work as expected there. The first block is the data located near...
4
3854
by: Thomas Paul Diffenbach | last post by:
Can anyone point me to an open source library of /statically allocated/ data structures? I'm writing some code that would benefit from trees, preferably self balancing, but on an embedded system that doesn't offer dynamic memory allocation (to be clear: no malloc, no realloc), and with rather tight memory constraints. Writing my own malloc to do dynamic allocation from some static pool isn't really an option, for various reasons, not...
1
2749
by: tony.fountaine | last post by:
I am working on a project to read a Bosch Measurement Data File (MDF). The file contains a number of blocks that can be read from the file using a baisc structure. For example the ID BLOCK is as follows, (Data Type) (Number of Elements) (Description) CHAR 8 File identifier, CHAR 8 Format identifier, CHAR 8 Program identifier,
4
2286
by: Thomas Eichner | last post by:
Hi, does anybody know a public website which offers a service that displays all data send by a browser (or an app calling the website), especially HTTP GET and POST data, browser data etc.? I have a hard time finding what really my app is sending and this would be a great help! Thank you very much ! Thomas
5
1841
by: harish2rock | last post by:
Hi..Me just a beginner in c++ programming. I have come acroos a program which is as follows : I have to prepare a file which contains the information in block format. as an example, the file will look like so: BEGIN PANELDATA BEGIN TITLE Panel Method for Saras Analsis. Run number 22. END TITLE
1
1707
by: selvialagar | last post by:
i have two select boxes in my form named month and year...when i selected these two things, there is a submit button called 'generate invoice'. when i click this, invoice report is generated as a table on the same page and i put customer number and block number in the hidden field in this step.....i have another link called 'payment' in the generated table for each row...when i click that link the form gets once again submitted....but, when i...
4
2554
by: Ty | last post by:
I have a SQL server 2000 DB that Ihave copied onto my PC and am using SQL server express 2005 to view. I created a project in VB.net and am reading the data out of the DB using System.Data.SqlClient Here is the problem. I am redaing the table fields into variables. All are fine except one. The table has one field that is a binary data type. This field holds
0
8394
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8732
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
8605
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
6164
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5632
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4152
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4304
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2726
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
1615
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.