|
|
Hi,
Is there any way of using a web proxy (i.e. using the WebProxy class in .NET) to send e-mails through as part of an e-mail client, without changing IE Settings?
The key is that I need to be able to mask IP addresses in e-mail headers sent from my e-mail client via an SMTP server, like GMail. The headers for GMail have the IP address in them if you don't send them from thei webmail cliet, you see...
Any and all help appreciated!
|
|
|
|
|
hi,
this question look silly but i need it.
i am extracting values from a pdf file and am assinging those values to a string array of fixed length. if i get extracted value as empty ( empty string) i have to assign that particular value as NULL . (becoz i have to insert this value into the database) using null option in the vb is not working. can any body help me ....
raj
-- modified at 5:27 Wednesday 1st February, 2006
|
|
|
|
|
Use DbNull.Value.
---
b { font-weight: normal; }
|
|
|
|
|
thanx for giving reply..
but dbNull inserting empty value into the database(sql server) . but i want it as "NULL" value.. ( i mean i want "NULL" word insted of empty )
raj
-- modified at 7:28 Wednesday 1st February, 2006
|
|
|
|
|
Make sure the table column is define as allowing nulls and doesn't have a default value specified.
|
|
|
|
|
hi,
i am sure the table column is define as allowing nulls ...
thank you
raj
|
|
|
|
|
I have tested both techniques and the database has the <null> value:
SqlCommand Lcomm;
DataSet Lds;
SqlDataAdapter Lda;
SqlCommandBuilder Lcb;
string LstrQueryString;
LstrQueryString = "Insert into Table1 (id, name) values (1, NULL)";
using (SqlConnection Lconn = new SqlConnection(@"Data Source=.\DA;Database=Testing;Integrated Security=SSPI"))
{
Lconn.Open();
Lcomm = new SqlCommand(LstrQueryString, Lconn);
Lcomm.ExecuteNonQuery();
LstrQueryString = "Select TOP 0 * From Table1";
Lds = new DataSet();
Lda = new SqlDataAdapter(LstrQueryString, Lconn);
Lcb = new SqlCommandBuilder(Lda);
Lda.Fill(Lds);
Lds.Tables[0].Rows.Add(2, System.DBNull.Value);
Lda.Update(Lds);
}
|
|
|
|
|
thanx for reply ...
But sir , u r inserting values threw query. but my values are in an external array. Like
str(0)="1234"
str(1)="$"
str(2)"asdf"
str(3)="qwer"
now i have to insert this values into the data base.
before inserting i am checking the string array for symbol "$".
but my question is if i get "$" i have to push that value as
NULL to the databse.
i tried for dbNUll but it inserting value as empty space NOT NULL.
like
LOOP:
if str(i)="$" then
str(i)= DbNULL
end if
END LOOP
"Insert into Table1 (name1,name2,name3,name4) values ('"& str(0) &"','"& str
(1) &"','"& str(2) &"','"& str(3) &"',)";
raj
|
|
|
|
|
Ooooh, now I understand what you are doing.
I believe you will have change you logic a little. The DBNull is only a database value. I believe if you change the code to the following this should solve you problem.
DataSet Lds;
SqlDataAdapter Lda;
SqlCommandBuilder Lcb;
object[] LaobjValues;
string LstrQueryString;
using (SqlConnection Lconn = new SqlConnection(@"Data Source=.\DA;Database=Testing;Integrated Security=SSPI"))
{
Lconn.Open();
LaobjValues = new object[2];
LaobjValues[0] = "5";
LaobjValues[1] = DBNull.Value;
LstrQueryString = "Select TOP 0 * From Table1";
Lds = new DataSet();
Lda = new SqlDataAdapter(LstrQueryString, Lconn);
Lcb = new SqlCommandBuilder(Lda);
Lda.Fill(Lds);
Lds.Tables[0].Rows.Add(LaobjValues[0], LaobjValues[1]);
Lda.Update(Lds);
}
|
|
|
|
|
thax for reply.
i done like what u have said. but now it is giving
error as object required. (rutime error '424')
thanx
raj
|
|
|
|
|
I'm looking for a grid in Windows.Form to display some data stored in RAM (arrays, collection, ...) and not in a database.
Reading the DataGrid documentation seems that it display only data stored in a database or in a XML file.
Is there a grid to do this ?
I'm using C# in Visual Studio 2003 and Framework 1.1.
nikolag
|
|
|
|
|
You can bind the DataGrid to various differnt sources including arrays/collections/etc.
You can also use ListView to display items in a grid. Use myListView.Items.Add(new ListViewItem(new string[] {"Value1","Value2"}));
Make sure you've added appropriate columns to the list view. Checkout the "Columns" property.
- Malhar
|
|
|
|
|
ok, the Microsoft documentation is not clear on this point .
Thank you for your help .
nikolag
"Tutti sanno che una cosa è impossibile da realizzare, finchè non arriva uno sprovveduto che non lo sa e la inventa"
(Albert Einstein)
|
|
|
|
|
I am looking for a short overview explanation of 1.1 vs 2.9 .NET differences. I realize there is the What's New in the .NET Framework Version 2.0 http://msdn2.microsoft.com/t357fb32.aspx[^]
But.... is there something a bit shorter that gives the major differences? I was thinking I could take the "What's New in the .NET Framework Version 2.0" and try to shorten it up. But maybe there is something out there already that gives a very quick summary? I am really looking for something that will allow me to still use old .NET framework documentation (hard-copy books ), and then have something to refer to to make sure any older documentation that I am reading is not too out-of-date.
|
|
|
|
|
LuluSailor wrote: I am looking for a short overview explanation of 1.1 vs 2.9 .NET differences. I realize there is the What's New in the .NET Framework Version 2.0 http://msdn2.microsoft.com/t357fb32.aspx[^]
That IS the summary version. There are over 200 new classes, 2,000 new methods, and some 1,200 changes to existing methods and properties. There's just no way you're going to be able to just "refer to the things that changed documentation" because the changes are in every corner of the Framework. I think your best shot is to just refer to the documentation for classes that you would be using and seeing what's changed and what's new.
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
Oh so very interesting! It looks like the summary is about 9-10 pages. ( I did copy the summary document and make it into outline format so I can see the main topic areas of change - see below). This might help a bit, but of course seeing just ADO.NET for example is not that helpful. I suppose as I go along I will start to see what changes are that significant over 1.1?
Main topics of change from the Microsoft document called "What’s new in the .NET Framework Version 2.0"
64-Bit Platform Support
Access Control List Support
ADO.NET
ASP.NET
Authenticated Streams
COM Interop Services Enhancements
Console Class Additions
Data Protection API
Debugger Display Attributes
Detecting Changes in Network Connectivity
Distributed Computing
EventLog Enhancements
Expanded Certificate Management
FTP Support
Generics and Generic Collections
Globalization
I/O Enhancements
Manifest-Based Activation
.NET Framework Remoting
Obtaining Information About Local Computer Network Configuration and Usage
Ping
Processing HTTP Requests from Within Applications
Programmatic Control of Caching
Programming Languages
Security Exceptions
Serial I/O Device Support
Serialization
SMTP Support
Strongly Typed Resource Support
Threading Improvements
Trace Data Filtering
Transactions
Web Services
Windows Forms–Related Features
XML-Related Features
-- modified at 22:10 Tuesday 31st January, 2006
|
|
|
|
|
|
dear all,
i want to copy a file from server to localhost.in server my file is located in"D:\folder\myfile.txt".i want to copy/save that file int my localhost in"D:\myfile.txt".how can i do this using vb.net?please give me the code as soon as possible...
by
barani
|
|
|
|
|
Here is fast and dirty solution
<br />
using System.Net;<br />
<br />
...<br />
...<br />
<br />
<br />
WebClient webClient = new WebClient();<br />
webClient.DownloadFile( "http://remotyeserver/myfile.txt", @"d:\myfile.txt" );<br />
Do the same using ftp is more complicated - but this ftp library[^] can help
DevIntelligence.com - My blog for .Net Developers
|
|
|
|
|
Hello,
Is there any help available for SPRIN .NET Framework ?
Pankaj Kulkarni
|
|
|
|
|
I assume you're talking about the Spring.NET Application Framework.
Try their Support Forums[^].
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
Hello,
I am working on a project that requires me to generate long reports that can have 150 pages or more - Each of these pages are generated as an A4 image (~3500x2480pixels), which is then inserted into an ArrayList...
The problem however is that I'm repeatedly getting OutOfMemory exceptions that I seem to be unable to get rid of despite extensively clearing all objects i'm not using (using the Image.Dispose() method for example) as well as forcing the garbage collector (GC.Collect()) every now and then...
I'm constructing each of these images in the 1bpp pixel format that would mean that each of these images would be ~1MB on average... For 200 images, this (crudely) corresponds to a 200MB ArrayList.. I agree this is a size larger than many RAMs, but shouldn't my computer be able use the pagefile (my pagefile is set to 512MB)??
Any one has any ideas on how I can get rid of, or even handle, these OutOfMemory exceptions??
Thanks,
Sarab
|
|
|
|
|
How are you using the report when it's finished, as you create the pages as images? Do they really have to be images?
Do you really have to create all images at the same time? Is there no way of handling the data of the report in some other way, and generate each image when you need it?
You could convert each image into GIF or PNG format, that would substantially reduce the size without losing any information.
---
b { font-weight: normal; }
|
|
|
|
|
If it were me, I'd try just saving each bitmap as it's created, and then just keeping an arraylist of filenames (files in a temporary location), accessing individual files as needed.
|
|
|
|