This is my Technical area of troubleshooting and learning new Programming skills and many more. Here you will find answers for many new technologies like asp.net 2.0/3.5,4.0 C# access, mysql, Amazon Webservice ,Sql-server, JD Edwards, SAS, Salesforce, APIs, MVC and many more. please visit & discuss.
Friday, February 26, 2010
Wednesday, February 24, 2010
Wednesday, February 17, 2010
Send Mass Email With Image ASP.NET C# sql-server
using
System.Data;using
System.Configuration;using
System.Net.Mail;using
System.Net.Mime;using
System.Collections.Generic;using
System.Web;using
System.Web.UI;using
System.Web.UI.WebControls;using
System.Data.SqlClient;
public
partial class sndmail : System.Web.UI.Page{
string strSQL; string txtEmail; protected void Page_Load(object sender, EventArgs e){
//Label1.Style.Add(
HtmlTextWriterStyle.BackgroundImage, "url(images//visliXmasFlyer2009.jpg)");}
protected void Button3_Click(object sender, EventArgs e){
ReadDB();
}
void ReadDB(){
SqlConnection myConnection = new SqlConnection(ConnectionString);strSQL =
"select * from mEmailList "; SqlCommand cmd = new SqlCommand(strSQL, myConnection);myConnection.Open();
SqlDataReader myReader = cmd.ExecuteReader(CommandBehavior.CloseConnection); // lableadid.Text = Request["LeadID"].ToString(); while (myReader.Read()){
Response.Write(txtEmail);
txtEmail = myReader[
"EmailID"].ToString();sndaamail();
}
myReader.Close();
myConnection.Close();
}
void sndaamail(){
string strMailContent = "<b><center><a href=http://visli.com> visli Warehouse Sale Coupon</a></center></b>"; string fromAddress = webmaster@visli.com; string toAddress = txtEmail.ToString(); string contentId = "image1"; string path = Server.MapPath(@"images/visliXmasFlyer2009.jpg"); // my logo is placed in images folder MailMessage mailMessage = new MailMessage(fromAddress, toAddress); //mailMessage.Bcc.Add(shivaliv@visli.com); // put your id heremailMessage.Subject =
"visli Warehouse Sale Coupon"; LinkedResource logo = new LinkedResource(path);logo.ContentId =
"companylogo"; // done HTML formatting in the next line to display my logo AlternateView av1 = AlternateView.CreateAlternateViewFromString("<html><body><a href=http://visli.com><img src=http://visli.com/images/visliXmasFlyer2009.jpg width=570px height=825px></a><br></body></html>" + strMailContent, null, MediaTypeNames.Text.Html);av1.LinkedResources.Add(logo);
mailMessage.AlternateViews.Add(av1);
mailMessage.IsBodyHtml =
true; //SmtpClient mailSender = new SmtpClient("10.0.1.32"); SmtpClient mailSender = new SmtpClient("mail.xxxxx.com");mailSender.Send(mailMessage);
}
private string ConnectionString{
get{
string connectionString = ConfigurationManager.ConnectionStrings["ConnectionString"].ConnectionString; return connectionString;}
}
}
Friday, February 12, 2010
Invalid parameter Manual payment Batch(M) - JD Edwards
This batch was mix with Domestic and Foreign currency and while posting got error in work center invalid parameter, to fix this Went to the file F0413 with Batch# found paymeny ID and modify all domastic payment As these entries are posted, using sql modify F0414 field RNPOST to D and also F0413 - RMISTP field to D. after that posted that batch, all entries got posted, After that reverse back above fields to P and posted that batch again, batch posted with no errors. So I took 2 steps to fix this batch.
Hotmail: Free, trusted and rich email service. Get it now.
Thursday, February 11, 2010
JD Edwards Mass Cost update for Items With Onhand Qty in inventory
Mass Cost update for Items With Onhand Qty in inventory
Today I did mass cost update by using Z-file Method
I order to do cost existing cost method cost update like 02 cost , you have to do following steps:
1. Populate F4105Z1 file using P4105Z1 Program these fields liitm,imlitm,limcu,'JDEIC' TranType,'A' "Transaction Action" ,'IC' CostMethod,'1' DirInd, UNCS Cost/Price.
2. Run R4105Z1I.
3. Check F4105 File if this created IC entries for the items you wanted to update cost(UNCS).Also check F4111 if this program created records in this file means you are doing something wrong. Check costing selc purchasaing , this field must keep Blank.Also see F0911 for no record created.
4. After that run R41052 in processing option put cost Method 02 (Depends on you which cost type you want to update)
and Doc type - IB in purge record put 1.
after this run you will see IB batch will create. so inventory cost is correct and GL is correct also.
How to See Macro VB Code In Excel?
How to Run an Access Query / Macro From Excel Spreadsheet?
Dim A As Object
Application.DisplayAlerts = False
Set A = CreateObject("Access.Application")
A.Visible = False
A.OpenCurrentDatabase ("Path of your database")
A.DoCmd.RunMacro "Name of your macro"
Application.DisplayAlerts = True
End Sub