public ActionResult Index(int id) { if (Session["U_id"] == null) { return(RedirectToAction("Index", "Home")); } else { MV db = new MV(); AP_Menu menu = new AP_Menu(); var r = Convert.ToInt32(Session["U_id"]); var user_id = r; var Menulist = db.user_rights(user_id); List <AP_Menu> menudisplay = menu.Menutree(Menulist, null); //Merge_Ads_images MAI = new Merge_Ads_images(); //MAI.ads = db.adsdetail(id); //MAI.images = db.adsdetailimages(id); //MAI.Menu = menudisplay; Ads ad = db.adsdetail(id); ViewBag.ads = ad; List <Ads> img_list = db.adsdetailimages(id); ViewBag.imglst = img_list; ViewBag.state = new SelectList(model.States, "S_id", "S_name"); ViewBag.category = new SelectList(model.Categories, "C_id", "C_Name"); return(View(menudisplay)); } }
public void Revive() { if (!hasRevived) { if (Ads.RewardAd()) { cameraDrop.SetActive(false); player.SetActive(true); hasRevived = true; deathMenu.SetActive(false); foreach (GameObject canvas in canvases) { canvas.SetActive(true); } } else { Debug.Log("Cannot revive!"); FindObjectOfType <AudioManager>().Play("Button"); } } else { Debug.Log("Cannot revive!"); } }
public void MergeFrom(ConfigSource other) { if (other == null) { return; } switch (other.ConfigSourceSpecifierCase) { case ConfigSourceSpecifierOneofCase.Path: Path = other.Path; break; case ConfigSourceSpecifierOneofCase.ApiConfigSource: if (ApiConfigSource == null) { ApiConfigSource = new global::Envoy.Api.V2.Core.ApiConfigSource(); } ApiConfigSource.MergeFrom(other.ApiConfigSource); break; case ConfigSourceSpecifierOneofCase.Ads: if (Ads == null) { Ads = new global::Envoy.Api.V2.Core.AggregatedConfigSource(); } Ads.MergeFrom(other.Ads); break; } _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); }
public int ReadFrom(byte[] Buffer, int StartIndex = 0) { int cursor = StartIndex; ushort len = BitConverter.ToUInt16(Buffer, cursor); cursor += TypeSizes.SHORT; for (ushort i = 0; i < len; i++) { Characters.Add(new CharSelectItem(Buffer, cursor)); cursor += Characters[i].ByteLength; } len = BitConverter.ToUInt16(Buffer, cursor); cursor += TypeSizes.SHORT; MOTD = Util.Encoding.GetString(Buffer, cursor, len); cursor += MOTD.Length; byte blen = Buffer[cursor]; cursor++; for (byte i = 0; i < blen; i++) { Ads.Add(new CharSelectAd(Buffer, cursor)); cursor += Ads[i].ByteLength; } return(cursor - StartIndex); }
public Ads adsdetail(int id) { Ads employee = new Ads(); using (SqlConnection conn = new SqlConnection(connstring)) { using (SqlCommand cmd = new SqlCommand("select p.P_id,p.P_Name , p.P_desc , p.Make , p.Condition , p.Ad_title ,p.Price,p.State_id,p.C_id,p.sold_product from Product_Master p where p.P_id = @p_id", conn)) { conn.Open(); cmd.Parameters.AddWithValue("@p_id", id); SqlDataReader reader = cmd.ExecuteReader(); reader.Read(); employee.p_id = Convert.ToInt16(reader["P_id"]); employee.P_name = reader["P_Name"].ToString(); employee.P_Desc = reader["P_desc"].ToString(); employee.Make = reader["Make"].ToString(); employee.Condition =reader["Condition"].ToString(); employee.Ad_title = reader["Ad_title"].ToString(); employee.Price =Convert.ToInt32( reader["Price"]); employee.State_id = Convert.ToInt32(reader["State_id"]); employee.C_id = Convert.ToInt32(reader["C_id"]); employee.sold_product = reader["sold_product"].ToString(); } } return employee; }
protected override void OnDisappearing() { base.OnDisappearing(); // Stop the ads Ads.Stop(); }
public List<Ads> adsdetailimages(int id) { List<Ads> DBase = new List<Ads>(); using (SqlConnection conn = new SqlConnection(connstring)) { using (SqlCommand cmd = new SqlCommand("select pd.id ,pd.P_id,pd.P_Images from Product_Detail pd where pd.P_id =@p_id ", conn)) { conn.Open(); cmd.Parameters.AddWithValue("@p_id", id); SqlDataReader reader = cmd.ExecuteReader(); while (reader.Read()) { Ads emp = new Ads(); emp.image_id= Convert.ToInt16(reader["id"]); emp.p_id = Convert.ToInt16(reader["P_id"]); emp.images = reader["P_Images"].ToString(); DBase.Add(emp); } } } return DBase; }
private async void OnNewAdsArrived(NotificationCenter arg1) { int adIdFrom = 0; if (Ads?.Count > 0) { adIdFrom = Ads.Max(ad => ad.Id); } var latestAds = await _apiClient.GetAds(Convert.ToInt32(ApplicationSettings.GetUserId()), adIdFrom); if (latestAds != null & latestAds.Count > 0) { foreach (var item in latestAds) { if (Ads.Count >= ADS_LIST_MAX_SIZE) { Ads.RemoveAt(Ads.Count - 1); } Ads.Insert(0, item); InternalCache.InsertAd(0, item); } } }
public void OnMouseDown() { BlackScreen.SetActive(true); iTween.MoveTo(Arcade30, iTween.Hash("position", new Vector3(-0.11f, 1.9f, -1), "time", 1f, "ignoretimescale", true)); iTween.MoveTo(Arcade60, iTween.Hash("position", new Vector3(-0.11f, -1f, -1), "time", 1)); Ads.Down(); }
public List<Ads> adscount(string id) { List<Ads> DBase = new List<Ads>(); using (SqlConnection conn = new SqlConnection(connstring)) { using (SqlCommand cmd = new SqlCommand("select p.p_date,count(*) as count_ad from Product_Master p where p.User_id = @id group by p.p_date", conn)) { conn.Open(); cmd.Parameters.AddWithValue("@id", id); SqlDataReader reader = cmd.ExecuteReader(); while (reader.Read()) { Ads emp = new Ads(); emp.p_Date = reader["p_date"].ToString(); /*Convert.ToDateTime(reader["p_date"]);*/ emp.count_ads = Convert.ToInt32(reader["count_ad"]); DBase.Add(emp); } } } return DBase; }
public override int GetHashCode() { int hash = 1; if (configSourceSpecifierCase_ == ConfigSourceSpecifierOneofCase.Path) { hash ^= Path.GetHashCode(); } if (configSourceSpecifierCase_ == ConfigSourceSpecifierOneofCase.ApiConfigSource) { hash ^= ApiConfigSource.GetHashCode(); } if (configSourceSpecifierCase_ == ConfigSourceSpecifierOneofCase.Ads) { hash ^= Ads.GetHashCode(); } if (initialFetchTimeout_ != null) { hash ^= InitialFetchTimeout.GetHashCode(); } hash ^= (int)configSourceSpecifierCase_; if (_unknownFields != null) { hash ^= _unknownFields.GetHashCode(); } return(hash); }
public void Run() { var ads = new Ads(); ads.formatVersion = 1; ads.target = "Avito.ru"; ads.Ad = new AdsAD[3]; ads.Ad[0] = GetAd(1); ads.Ad[1] = GetAd(2); ads.Ad[2] = GetAd(3); //Serialize the class into a file XmlSerializer xs = new XmlSerializer(typeof(Ads)); FileStream fs = new FileStream(@"D:\Test\test.xml", FileMode.Create); xs.Serialize(fs, ads); fs.Close(); //Deserialize the file into an instance of the class xs = new XmlSerializer(typeof(Ads)); fs = new FileStream(@"D:\Test\test.xml", FileMode.Open); Ads mc = (Ads)xs.Deserialize(fs); fs.Close(); }
public async Task <int> Update_By_Id(Ads obj) { using (var con = DbHelper.GetSqlConnection()) { return(await con.ExecuteAsync(Update_By_IdSP, new { obj.Id, obj.PageName, obj.AdScript, obj.Active }, commandType : CommandType.StoredProcedure)); } }
public void InsertAds(Ads empl) { using (SqlConnection conn = new SqlConnection(connstring)) { using (SqlCommand cmd = new SqlCommand("insert into Product_Master(P_id ,P_date ,P_Name,P_desc,User_id,Make,Condition,Ad_title,Price,State_id,C_id) values (@P_id,@p_date,@P_name , @P_desc ,@P_user_id ,@p_make ,@p_cond ,@p_title ,@P_price ,@state_id ,@c_id)", conn)) { conn.Open(); cmd.Parameters.AddWithValue("@P_id", empl.p_id); cmd.Parameters.AddWithValue("@p_date", empl.p_Date); cmd.Parameters.AddWithValue("@P_name", empl.P_name); cmd.Parameters.AddWithValue("@P_desc", empl.P_Desc); cmd.Parameters.AddWithValue("@P_user_id", empl.User_id); cmd.Parameters.AddWithValue("@p_make", empl.Make); cmd.Parameters.AddWithValue("@p_cond", empl.Condition); cmd.Parameters.AddWithValue("@p_title", empl.Ad_title); cmd.Parameters.AddWithValue("@P_price", empl.Price); cmd.Parameters.AddWithValue("@state_id", empl.State_id); cmd.Parameters.AddWithValue("@c_id", empl.C_id); cmd.ExecuteNonQuery(); } } }
void Awake() { if (!instance) { instance = this; } }
public List<Ads> Searchdata(string id) { List<Ads> DBase = new List<Ads>(); using (SqlConnection conn = new SqlConnection(connstring)) { using (SqlCommand cmd = new SqlCommand("Searchwithitems", conn)) { cmd.CommandType = System.Data.CommandType.StoredProcedure; conn.Open(); cmd.Parameters.AddWithValue("@C_Name", id); SqlDataReader reader = cmd.ExecuteReader(); while (reader.Read()) { Ads emp = new Ads(); emp.p_id = Convert.ToInt16(reader["P_id"]); emp.p_Date = reader["p_date"].ToString(); emp.P_name = reader["P_Name"].ToString(); emp.P_Desc = reader["P_desc"].ToString(); emp.Price = Convert.ToInt32(reader["Price"]); emp.images = reader["p_image"].ToString(); DBase.Add(emp); } } } return DBase; }
public void updateemp(Ads empl) { using (SqlConnection conn = new SqlConnection(connstring)) { using (SqlCommand cmd = new SqlCommand("update Product_Master set P_Name=@P_name ,P_desc= @P_desc ,Make = @p_make , Condition = @p_cond , Ad_title = @p_title , Price = @P_price , State_id = @state_id ,C_id= @c_id,sold_product = @s_p where P_id = @p_id", conn)) { conn.Open(); cmd.Parameters.AddWithValue("@p_id", empl.p_id); cmd.Parameters.AddWithValue("@P_name", empl.P_name); cmd.Parameters.AddWithValue("@P_desc", empl.P_Desc); cmd.Parameters.AddWithValue("@p_make", empl.Make); cmd.Parameters.AddWithValue("@p_cond", empl.Condition); cmd.Parameters.AddWithValue("@p_title", empl.Ad_title); cmd.Parameters.AddWithValue("@P_price", empl.Price); cmd.Parameters.AddWithValue("@state_id", empl.State_id); cmd.Parameters.AddWithValue("@c_id", empl.C_id); cmd.Parameters.AddWithValue("@s_p", empl.sold_product); cmd.ExecuteNonQuery(); } } }
public async Task <List <Ads> > UploadVideoAds(IFormFileCollection formFiles) { List <Ads> fileCreates = new List <Ads>(); if (formFiles != null && formFiles.Count > 0) { foreach (var file in formFiles) { var fileName = Guid.NewGuid().ToString(); fileName = fileName + Path.GetExtension(file.FileName); var fileUrl = "/ads/" + fileName; var filePath = Path.Combine(Directory.GetCurrentDirectory(), @"wwwroot\ads", fileName); using (var fileStream = new FileStream(filePath, FileMode.Create)) { await file.CopyToAsync(fileStream); } if (fileName != "") { var fileDoneUpload = new Ads { name = fileName, url = fileUrl }; fileCreates.Add(fileDoneUpload); } } } return(fileCreates); }
public IActionResult GetAdsList(string keyword, int page = 1, int limit = 20, int kid = 0) { int numPerPage, currentPage, startRowIndex; numPerPage = limit; currentPage = page; startRowIndex = (currentPage - 1) * numPerPage; Expression ex = Ads._.Id > 0; if (kid > 0) { ex &= Ads._.KId == kid; } if (!string.IsNullOrWhiteSpace(keyword)) { ex &= Ads._.Title.Contains(keyword); } IList <Ads> list = Ads.FindAll(ex, Ads._.Sequence.Asc().And(Ads._.Id.Desc()), null, startRowIndex, numPerPage); long totalCount = Ads.FindCount(ex, Ads._.Sequence.Asc().And(Ads._.Id.Desc()), null, startRowIndex, numPerPage); return(Content(Newtonsoft.Json.JsonConvert.SerializeObject(new { total = totalCount, rows = list }), "text/plain")); //return Json(new { total = totalCount, rows = list }, JsonRequestBehavior.AllowGet); }
public Ads promstrdata(int id) { Ads employee = new Ads(); using (SqlConnection conn = new SqlConnection(connstring)) { using (SqlCommand cmd = new SqlCommand("select m.p_id , m.P_date , m.P_Name , m.P_desc , m.Make , m.Condition , m.Ad_title , m.Price , s.S_name , c.C_Name , m.sold_product ,l.User_id, l.User_name , l.User_contact , ISNULL(l.User_Profile,'~/Content/Images/user.png') as user_profile from Product_Master m , State s , Category c , login l where m.State_id = s.S_id and m.C_id = c.C_id and l.User_id = m.User_id and m.P_id = @P_id", conn)) { conn.Open(); cmd.Parameters.AddWithValue("@P_id", id); SqlDataReader reader = cmd.ExecuteReader(); reader.Read(); employee.p_id = Convert.ToInt16(reader["P_id"]); employee.P_name = reader["P_Name"].ToString(); employee.P_Desc = reader["P_desc"].ToString(); employee.Make = reader["Make"].ToString(); employee.Condition = reader["Condition"].ToString(); employee.Ad_title = reader["Ad_title"].ToString(); employee.Price = Convert.ToInt32(reader["Price"]); employee.State_Name = reader["S_name"].ToString(); employee.category_Name = reader["C_Name"].ToString(); employee.sold_product = reader["sold_product"].ToString(); employee.User_id = Convert.ToInt16(reader["User_id"]); employee.User_name = reader["User_name"].ToString(); employee.User_contact = reader["User_contact"].ToString(); employee.user_profile = reader["user_profile"].ToString(); } } return employee; }
public ActionResult AdSave(HttpPostedFileBase adImage = null) { string saveName = ""; try { if (adImage != null) { // 文件上传后的保存路径 var filePath = Server.MapPath(string.Format("~/{0}", "ads")); if (!Directory.Exists(filePath)) { Directory.CreateDirectory(filePath); } var fileName = Path.GetFileName(adImage.FileName); string fileExtension = Path.GetExtension(fileName); // 文件扩展名 saveName = Guid.NewGuid().ToString("n") + fileExtension; // 保存文件名称 adImage.SaveAs(Path.Combine(filePath, saveName)); } } catch (Exception ex) { return(Json(BuildAjaxBackResult(new ReturnMessage(EnumResultState.Failing.ToString(), "处理失败,保存文件错误!")))); } ReturnMessage messge = Ads.NewAd(saveName); return(Json(BuildAjaxBackResult(messge))); }
public IHttpActionResult SendAll(Ads ads) { if (ads == null) { return(Json(new { success = false, message = "id error" })); } MailUtil mailUtil = new MailUtil(); var listEmail = orderDO.GetListEmail(); Product product = db.Products.Find(ads.ProductID); if (product == null) { return(Json(new { success = false, message = "product not found" })); } scheduler = new Thread(() => sendMailFT(listEmail, mailUtil.CreateBodyAds(product), "Alimenswear Ads")); scheduler.Start(); return(Json(new { success = true, message = "acction success" })); }
public Ads earntotal(int id) { Ads employee = new Ads(); using (SqlConnection conn = new SqlConnection(connstring)) { using (SqlCommand cmd = new SqlCommand("select sum(m.Price) price from Product_Master m where m.User_id = @p_id and m.Sold_product = 'Y' group by m.User_id", conn)) { conn.Open(); cmd.Parameters.AddWithValue("@p_id", id); SqlDataReader reader = cmd.ExecuteReader(); if (reader.Read()) { employee.Price = Convert.ToInt16(reader["price"]); } } } return employee; }
public List<Ads> userfetchdetail(int id) { List<Ads> DBase = new List<Ads>(); using (SqlConnection conn = new SqlConnection(connstring)) { using (SqlCommand cmd = new SqlCommand("select l.User_name , l.User_email , l.User_contact, l.Last_login,l.User_Active from login l", conn)) { conn.Open(); SqlDataReader reader = cmd.ExecuteReader(); while (reader.Read()) { Ads emp = new Ads(); emp.User_name = reader["User_name"].ToString(); emp.user_email = reader["User_email"].ToString(); emp.User_contact = reader["User_contact"].ToString(); if (reader["Last_login"] != DBNull.Value) { emp.Last_login = Convert.ToDateTime(reader["Last_login"]); } emp.User_active = reader["User_Active"].ToString(); DBase.Add(emp); } } } return DBase; }
public List<Ads> userdetailfetch() { List<Ads> DBase = new List<Ads>(); using (SqlConnection conn = new SqlConnection(connstring)) { using (SqlCommand cmd = new SqlCommand("select p.P_date , p.P_Name, l.User_name , p.Make , p.Price , s.S_name , p.Sold_product from Product_Master p , login l , state s where p.User_id = l.User_id and p.State_id = s.S_id", conn)) { conn.Open(); SqlDataReader reader = cmd.ExecuteReader(); while (reader.Read()) { Ads emp = new Ads(); emp.p_Date = reader["P_date"].ToString(); emp.P_name = reader["P_Name"].ToString(); emp.User_name = reader["User_name"].ToString(); emp.Make = reader["Make"].ToString(); emp.Price = Convert.ToInt32( reader["Price"]); emp.State_Name = reader["S_name"].ToString(); emp.sold_product = reader["Sold_product"].ToString(); DBase.Add(emp); } } } return DBase; }
public List<Ads> bid_records(int id) { List<Ads> DBase = new List<Ads>(); using (SqlConnection conn = new SqlConnection(connstring)) { using (SqlCommand cmd = new SqlCommand("select p.P_id,p.P_Name , p.Ad_title , p.Condition , p.Make, p.Price , count(b.p_id)count_bid from BID b , Product_Master p where b.p_id = p.P_id and p.User_id = @id group by p.p_id,p.P_Name , p.Ad_title , p.Condition , p.Make, p.Price", conn)) { conn.Open(); cmd.Parameters.AddWithValue("@id", id); SqlDataReader reader = cmd.ExecuteReader(); while (reader.Read()) { Ads emp = new Ads(); emp.p_id = Convert.ToInt32(reader["P_id"]); emp.P_name = reader["P_Name"].ToString(); emp.Ad_title = reader["Ad_title"].ToString(); emp.Condition = reader["Condition"].ToString(); emp.Make = reader["Make"].ToString(); emp.Price = Convert.ToInt32(reader["Price"]); emp.bid = Convert.ToInt32(reader["count_bid"]); DBase.Add(emp); } } } return DBase; }
/// <summary> /// 获取广告实体 /// </summary> /// <param name="ID">广告ID</param> /// <returns>广告实体</returns> public Ads GetAds(int ID) { string sqlQuery = string.Format(" WHERE ID={0}", ID); Ads ads = aideAdsProvider.GetObject <Ads>(sqlQuery); return(ads); }
public async Task <Ads> Add_New(Ads obj) { using (var con = DbHelper.GetSqlConnection()) { return(await con.QueryFirstOrDefaultAsync <Ads>(Add_NewSP, new { obj.Active, obj.AdScript, obj.PageName }, commandType : CommandType.StoredProcedure)); } }
private void AddSubs() { SceneManager.sceneLoaded += OnSceneLoaded; SceneManager.sceneUnloaded += OnSceneUnloaded; AddEvent(EventConstants.GAME_OVER, () => { backgroundAudio.Stop(); SceneManager.LoadScene(SceneConstants.GAME_OVER, LoadSceneMode.Additive); Ads.ShowVideo(); }); AddEvent(EventConstants.LEVEL_COMPLETED, () => { backgroundAudio.Stop(); PlayerPrefs.SetInt(PlayerPrefsConstants.COMPLETED_LEVEL, level); SceneManager.LoadScene(SceneConstants.LEVEL_COMPLETED, LoadSceneMode.Additive); Ads.ShowVideo(true); }); AddEvent(EventConstants.OPEN_MAP, () => SceneManager.LoadScene(SceneConstants.MAP, LoadSceneMode.Additive) ); AddEvent(EventConstants.PAUSE, () => SceneManager.LoadScene(SceneConstants.PAUSE_MENU, LoadSceneMode.Additive) ); }
public List<Ads> getimagewisedata() { List<Ads> DBase = new List<Ads>(); using (SqlConnection conn = new SqlConnection(connstring)) { using (SqlCommand cmd = new SqlCommand("fetchimagewisedata", conn)) { cmd.CommandType = System.Data.CommandType.StoredProcedure; conn.Open(); SqlDataReader reader = cmd.ExecuteReader(); while (reader.Read()) { Ads emp = new Ads(); emp.p_id = Convert.ToInt16(reader["P_id"]); emp.p_Date = reader["p_date"].ToString(); emp.P_name = reader["P_Name"].ToString(); emp.P_Desc = reader["P_desc"].ToString(); emp.Price = Convert.ToInt32( reader["Price"]); emp.images = reader["p_image"].ToString(); emp.sold_product = reader["Sold_product"].ToString(); DBase.Add(emp); } } } return DBase; }
/// <summary> /// Use the app account settings from developer.att.com for the following values. /// Make sure ADS is enabled for the App Key and the App Secret. /// </summary> protected void Page_Load(object sender, EventArgs e) { // Enter the value from the 'App Key' field obtained at developer.att.com in your // app account. string appKey = ""; // Enter the value from the 'App Secret' field obtained at developer.att.com // in your app account. string appSecret = ""; // Set the fully-qualified domain name to: https://api.att.com string fqdn = "https://api.att.com"; //Set the scope to ADS string scope = "ADS"; // Create the service for requesting an OAuth access token. var oauth = new OAuth(fqdn, appKey, appSecret, scope); // Get the OAuth access token using the Client Credentials. if (oauth.GetAccessToken(OAuth.AccessTokenType.ClientCredentials)) { // Get access token OAuthToken at = new OAuthToken(); var accessToken = at.getAccessToken(oauth.accessTokenJson); // Create the service for making the method request. var ads = new Ads(fqdn, accessToken); // Set params: string category = "Auto"; string udid = "123456789012345678901234567890"; string userAgent ="Mozilla/5.0 (Linux; Android 4.0.4; Galaxy Nexus Build/IMM76B) AppleWebKit/535.19 (KHTML, like Gecko) Chrome/18.0.1025.133 Mobile Safari/535.19"; try { // Make an Make a method call to the Advertising API. // param 1 category // param 2 udid // param 3 user agent AdsObj.RootObject ads_obj = ads.GetAds(category, udid, userAgent); } catch (Exception ex) { string error = ex.StackTrace; } } }
protected void ImageButtonFold_Click(object sender, ImageClickEventArgs e) { Ads ads = new Ads(); ads.editAd("Fold", CheckBoxFold.Checked, TextBoxFoldLink.Text, TextBoxFoldImage.Text); }
protected void ImageButtonCoupons_Click(object sender, ImageClickEventArgs e) { Ads ads = new Ads(); ads.editAd("Coupons", CheckBoxCoupons.Checked, TextBoxCouponsLink.Text, TextBoxCouponsImage.Text); }
protected void ImageButtonTop_Click(object sender, ImageClickEventArgs e) { Ads ads = new Ads(); ads.editAd("Top", CheckBoxTop.Checked, TextBoxTopLink.Text, TextBoxTopImage.Text); }
protected void ImageButtonOffers_Click(object sender, ImageClickEventArgs e) { Ads ads = new Ads(); ads.editAd("Offers", CheckBoxOffers.Checked, TextBoxOffersLink.Text, TextBoxOffersImage.Text); }
protected void ImageButtonLogin_Click(object sender, ImageClickEventArgs e) { Ads ads = new Ads(); ads.editAd("Login", CheckBoxLogin.Checked, TextBoxLoginLink.Text, TextBoxLoginImage.Text); }
protected void ImageButtonBottom_Click(object sender, ImageClickEventArgs e) { Ads ads = new Ads(); ads.editAd("Bottom", CheckBoxBottom.Checked, TextBoxBottomLink.Text, TextBoxBottomImage.Text); }