I was able to take what you suggested above and make it work. I just placed the code in the Page_Load Event, and then call it inside the RowDataBound Event.
There is probably a better way to do this (and a cleaner way) but this will work for now.
StringBuilder str = new StringBuilder("...
I had a look around and couldn't come up with a way to keep the grid from doing a trim.
I'll give your solution a shot and see what I can come up with.
Thanks for the help!
Thanks,
Chilly442
---------------------------------------
So I loop through the dtEvents DataTable and get the values that I need. I do some checking, which I have left out.
Then I build the dtMaster_Events DataTable and bind that to the Grid.
I tried:
sC4 = new String(' ', 20);
//===
And a few variations of:
String sSpace = " ";
sC4 = sSpace +...
I am attempting to build a text report from data that is loaded into a GridView.
The GridView is populated from a DataTable which is filled with data from a query.
Each column is required to be a fixed number of spaces or characters.
The problem that I am having is there are a few columns in...
I have a dashboard that is supposed to run 24 hours a day to display last hours data for power generation. Values are pulled from oracle and refreshed to the pages every hour to keep the data current. A rotator changes the page every 45 seconds using a timer control. At this time I have a...
After doing a bit more research into this, I was looking on Microsoft's site and found the following:
http://msdn.microsoft.com/en-us/library/system.data.oracleclient(v=VS.100).aspx
Looks like OracleClient is going to go away in future versions.
Thanks,
Chilly442...
I have been using ODBC to connect and query data from Oracle. I had a co-worker tell me that he doesn't think that I should be using ODBC, and that he uses OracleClient.
What is/are the benefits to using one or the other?
Am I better off using one and not the other?
Using ODBC is what I...
It is stored as a Date.
Thanks for taking the time to help me.
Thanks,
Chilly442
---------------------------------------
If I lived anywhere else I'd be Sunny442
When I run the following query, it returns dates that are before 2010 and I am not sure why.
SELECT * FROM Events WHERE (Unit = 'D5') AND StartTime >= TO_DATE('01/01/2010', 'MM/DD/YYYY')
Is this because the Oracle DB has the dates stored as "MM/dd/yyyy HH:MM:SS"?
If so what do I need to...
I am converting an application that was written in VB to C#. I am trying to test this query to pull data from Oracle. This query gives me anything = or > STime, but ignores the year.
So if STime = 01/01/2010 12:00:00
I get 01/01/1998 12:00:00, 03/03/1995 11:00:00
I need anything that is...
In your query you need to tell it to pull the values as a number.
In Oracle it is:
To_Number(ID)
Thanks,
Chilly442
---------------------------------------
If I lived anywhere else I'd be Sunny442
Looking for advice for the best solution:
I have an Excel file that users enter monthly data into. Users will leave the file open and then go to lunch, or leave for the weekend. So other users are not able to get into the file and do their work.
What is the best soluion to prevent or fix...
After a bit more searching I found this:
TextBox1.Attributes.Add("onkeydown", "return (event.keyCode!=13);")
If placed in the PageLoad it takes care of my problem.
Thanks to all who tried to help.
Sorry it took so long to post this.
Thanks,
Chilly442...
Try something like this:
Sub GridView1_RowUpdating(ByVal sender As Object, ByVal e As GridViewUpdateEventArgs)
Dim strVehicle As String = DirectCast(GridView1.Rows(e.RowIndex).Cells(2).Controls(0), TextBox).Text
Dim strNotes As String =...
I am still new to this as well.
jbenson001
Why not? What is the downfall?
Just curious.
Thanks,
Chilly442
---------------------------------------
If I lived anywhere else I'd be Sunny442
There are multiple graphs/views that can be generated. We have an excel file (not related to this project) that builds presentations for our power plants based on the graphs in the excel file. They were just thinking we could do the same thing with this application.
I like the idea of...
I custom build some graphs in my code behind on a report page. The user selects a unit and a date range and I run a query to populate the graphs.
Now the boss wants to have a button that will run all the graphs and copy them into a powerpoint presentation.
Our production server does not have...
What OS are you using?
On Vista (at home) the only way I can use break points is to run as administrator.
Thanks,
Chilly442
---------------------------------------
If I lived anywhere else I'd be Sunny442
I use this to display the user's selected Date in a text box. The calendar is a standard control from the toolbox.
Sub Calendar1_SelectionChanged(ByVal sender As System.Object, _
ByVal e As System.EventArgs) Handles Calendar1.SelectionChanged
Me.TextBox1.Text =...
Thanks. I have tested the code without the stuff I deleted and have not had any issues yet. I am not even sure where they came from.
Thank you for all your help. You have saved me a few times.
Thanks,
Chilly442
---------------------------------------
If I lived anywhere else I'd be Sunny442
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.