Click here to Skip to main content
14,663,485 members

Comments by ahmed_sa (Top 200 by date)

ahmed_sa 13-Sep-20 2:50am View
thank you for reply
Expected result is :
1222 3491
but i get it wrong as
2243 2243
when apply answer above
can you help me get correct answer
ahmed_sa 8-Sep-20 6:30am View
sorry function exist on
dbo.split function exist on
ahmed_sa 8-Sep-20 2:58am View
dbo.split are built in function
ahmed_sa 5-Aug-20 21:02pm View
so please what I do
ahmed_sa 22-Jul-20 6:41am View
so what I do to enhance performance of that long query
ahmed_sa 22-Jul-20 6:40am View
so what I do to do that fast
ahmed_sa 17-Jun-20 21:56pm View
I need to make result above as SQL function so how to do that .
what I try give me correct result only what i need to do converting code above to SQL function
ahmed_sa 4-Jun-20 6:46am View
if possible can you help me by showing code
ahmed_sa 2-Jun-20 11:47am View
I got what you mean you mean then when I make return new SQL connection this meaning
this is not static because I take new object my question are connection with this way is good or bad
ahmed_sa 2-Jun-20 11:27am View
I read it but I need ask are my work is wrong and if I change my connection above to get query from another server what issue I will solve
please help me
ahmed_sa 2-Jun-20 10:58am View
so my question are using connection as I used is correct or what ?
ahmed_sa 22-May-20 19:44pm View
thank you for reply i need to prevent it from display by using filter because totalCount display as last column on table
and i dont need to display it
ahmed_sa 14-Apr-20 9:13am View
I modify my original post if any more details i will explain to you
ahmed_sa 14-Apr-20 7:15am View
thank you for reply it is not give me correct result
remaining record number 5 and 6
as link
i do
delete t from #TradeCode t
left join #MappingCodeValue as m
on (t.codetype = m.parentcodetype) and (t.codevalue = m.parentcodevalue)
where m.parentcodetype is null and m.parentcodevalue is null
select * from #TradeCode

TradeCodeId PartId CodeType CodeValue partlevel PartDone
1 1222 ECCS-US AB123-US 0 NULL
2 1255 ECCS-US AB555-US 0 NULL
11 1255 HTS-US AB900-US 0 NULL
12 909 HTS-US AB900-US 0 NULL
ahmed_sa 1-Apr-20 4:03am View
OK i understand
ahmed_sa 1-Apr-20 3:41am View
thank you very much for help for support
I really get more benefit from that forum so much
and i learn so much .
sometimes i ask questions to get more efficient answer to my questions
OK i understand about what you talk above and i will improve my self
only one question i need answer for it
you confuse because task is trivial or Im not try .
please tell me i lookup to Learn from my wrong to not repeat again ?
ahmed_sa 31-Mar-20 17:32pm View
I solved my issue
thank you
this is my answer
declare @SeletColumnComma varchar(max)
select @SeletColumnComma = coalesce(@SeletColumnComma + ',','') + coalesce('substring(DoneCode ,' +cast (FunctionId as nvarchar(20)) + ',1) as ' + FunctionName + '','') from #Donecode
select @SeletColumnComma

DECLARE @query nvarchar(max)
SET @query='select ' + @SeletColumnComma + ' from #filedetails'
ahmed_sa 24-Mar-20 7:38am View
I ask this question because i need to access my laravel project from another machine on lan
locally laravel project work
but it not work ovrer lan
can you please tell me what i do to see my app from another pc on my lan
i use ip and i can see that ip from anoter pc
but laravel project cannot see it
although it work locally
ahmed_sa 23-Mar-20 13:29pm View
which tool need to install and what i do to solve this issue
ahmed_sa 19-Mar-20 6:06am View
it is found on this link
ahmed_sa 16-Mar-20 6:29am View
can you see execution plan above
ahmed_sa 24-Feb-20 10:04am View
I need to write function with make same as API above
ahmed_sa 24-Feb-20 10:03am View
I need to write function with make same as above
ahmed_sa 23-Feb-20 5:19am View
no i dont need that i need it on angular 7 what i do to receive value of count
my API return number as 100
how to receive on angular 7 and display on component.html
ahmed_sa 18-Feb-20 4:14am View
Thanks for reply i ask here only to give me some idea about what i make only and give me public reasons for that
ahmed_sa 17-Feb-20 10:25am View
what you mean this line please
also fire the Send Alert method you have yet to write
are this meaning windows notifications or send by email
can you tell me what you mean by line above if possible ?
ahmed_sa 17-Feb-20 5:40am View
thank you for reply by email using core 2.2
ahmed_sa 13-Feb-20 8:33am View
OK this i will do and while loop what alternative to it
ahmed_sa 13-Feb-20 7:10am View
I Update my script query full so can you help me please if p[ossible
if there are any solution without using while loop
ahmed_sa 13-Feb-20 4:17am View
can i write my query above without using while loop solutions
ahmed_sa 13-Feb-20 1:35am View
OK and what about select top 5000 exist inside loop
are this OK or have something issue
ahmed_sa 11-Feb-20 8:47am View
can any one help me please
ahmed_sa 10-Feb-20 17:54pm View
my problem in @Columns variables before union all not show dynamic values but after union all it display dynamic values so How to solve this problem
ahmed_sa 6-Feb-20 6:27am View
please can you help me to do that on angular 7
ahmed_sa 3-Feb-20 22:41pm View
but i face problem on this line
FeatureName IN (' + @Columns + ')
ahmed_sa 3-Feb-20 22:30pm View
can you help me
i need to run as select statement
see How to run that
SELECT @Columns =
COALESCE(@Columns + ', ','') + QUOTENAME(FeatureName)
--distinct FT.FeatureName
(select distinct FT.FeatureName from #InputData Feat inner join #ItemFeatures ItemF
on ItemF.CustomerId=Feat.CustomerId INNER join #FeatureType FT on ItemF.FeatureId=FT.FeatureId

) AS B
ORDER BY B.FeatureName

SELECT ItemCode, IPN,PartnerName,CustomerName, ' + @Columns + '
select F.ItemId,F.ItemId as ItemCode,I.IPN,I.PartnerName,I.PartnerPart,c.CustomerName,t.FeatureName from #InputData Itm
inner join #ItemFeatures F on F.CustomerId=Itm.CustomerId
inner join #Items I on I.ItemID=F.ItemId
inner join #FeatureType T on T.FeatureId=F.FeatureId
inner join #customers c on c.CustomerID=F.CustomerID
) as PivotData
FOR FeatureName IN (' + @Columns + ')
) AS PivotResult
ORDER BY CustomerName
ahmed_sa 1-Feb-20 18:06pm View
thank you for reply
how to concate number of characters from string
meaning i need to use concate for 150 from string
ahmed_sa 28-Jan-20 4:16am View
this is correct or wrong
ahmed_sa 28-Jan-20 3:30am View
why AND TCC.codeType IS NULL
t.CodeType IS NULL IS enough
ahmed_sa 25-Jan-20 4:30am View
I have insertiondate on table have formate dd/mm/yyyy

I need when user write any formate different from dd/mm/yyyy

like mm/dd/yyyy or yyyy/mm/dd

convert to dd/mm/yyyy

How to do that please ?
ahmed_sa 24-Jan-20 7:54am View
thank you very much
ahmed_sa 24-Jan-20 7:41am View
thank you for reply
statement i write (not in)
give me correct result
but I need using join with where if there are condition
are this possible or not
ahmed_sa 22-Jan-20 8:17am View
thanks for help
ahmed_sa 22-Jan-20 8:05am View
above it based on partid i need to display based on tradecode
on my case every trade code have group of parts
when trade code on tempsupplier is 15
this meaning i will display all parts that exist on temp parts and not exist on temp trade code
missing i need to get is missing from trade code
ahmed_sa 22-Jan-20 7:33am View
I need missing parts on level of tradecode not level of part meaning parts have related parts 1,2,3 then i will search for missing on temp table parts meaning any part different from 1,2,3
ahmed_sa 22-Jan-20 6:14am View
i explain more and post final result at end
ahmed_sa 13-Jan-20 13:24pm View
my wrong on that question is I cannot put points above on google map
so please i need help
I need resume code above to pinpoint these locations above on google map
ahmed_sa 13-Jan-20 8:38am View
there is no error display on inspect
ahmed_sa 12-Jan-20 6:05am View
can you tell me what final code i modify to get access to value of userPass
ahmed_sa 12-Jan-20 5:05am View
console.log("check new" + auth[0]);
it give me
check new[
ahmed_sa 12-Jan-20 4:53am View
thank you for reply
I have array have one object
id do as you told me above
auth = localStorage.getItem('LoginUserData');
console.log("auth is" + localStorage.getItem('LoginUserData'));

let pass = auth[0].userPass;
console.log("check new" + pass);
result on browser
error undefined
How to solve this problem ?

auth is[{"userLoginID":0,"userName":"test","userMail":"","userPass":"fayez123","fkTeamID":0,"isAdmin":false,"createdBy":0,"createdDate":"0001-01-01T00:00:00","isHidden":false}]
changepassword.component.ts:68 check newundefined
ahmed_sa 11-Jan-20 12:59pm View
No can you tell me how to use it to trace problem
ahmed_sa 10-Jan-20 16:39pm View
i want to validate old password with new password but problem i have validation on form to new password and confirm password
so please my question how to make two custom validation on reactive form
more than one
createFormResetPassword() {
this.ChangePasswordForm ={

oldPassword: this.oldPassword,
newPass: this.newPass,
confirmedPassword: this.confirmedPassword
{ validator: MustMatch('newPass', 'confirmedPassword')}
// error here not accept { validator: MustnotMatch('oldPassword', 'newPass')}


so how to add more custom validation to reactive form
ahmed_sa 9-Jan-20 2:50am View
thank you for reply this is not same question
if i ask more question on one question it will difficult for understand
ahmed_sa 7-Jan-20 10:55am View
can any one help me
ahmed_sa 7-Jan-20 4:55am View
thank you for reply actually my problem points of latitude and longitude not display on google map although I have points so actually I need points above show or display on google map so How to do that please if possible help me
ahmed_sa 18-Dec-19 8:51am View
can you give me any example
ahmed_sa 5-Dec-19 5:55am View
I get this code already from this article can you help me implementing that on core 2.2
ahmed_sa 3-Dec-19 21:17pm View
i get repeated datan
i see repeated company and revision
ahmed_sa 2-Dec-19 22:02pm View
sample data to expected result

zprtid forign key for table [Parts].[Nop_Part]
id zpartid revisionid
9000 2 1000
9001 90 1000
9002 50 1000
9003 70 2000
9004 75 2000
9005 40 3000
[Parts].[Nop_Part] represent main parts
partid not repeated
PartID PartName CompanyID
2 trans 10
90 resis 10
50 speaker 10
70 screen 40
75 lcd 40
40 converter 70

CompanyID CompanyName
ahmed_sa 29-Nov-19 10:00am View
thank you i mean error exist on which line not error message
5 error here
if i work on stored procedure have big amount of lines
i need if stored procedure have error tell me
error on line number 5 like that
ahmed_sa 22-Nov-19 18:20pm View
thank you very much but remaining some points not understand about second answer or post
actually i need function generic as second thread but something not clear
1- what you mean executequery
command not have excute query
2- how to fill data or result please
can you complete second function if possible
ahmed_sa 9-Nov-19 10:25am View
sql server 2012
ahmed_sa 6-Nov-19 7:42am View
can you please tell me how to make empty temp table #result on query above
ahmed_sa 24-Oct-19 0:01am View
thank you for reply
according to permission file system and my project i give full access control read and write and create
my publish for both me and iis users
can you tell me what can i try after that
it take too much time
ahmed_sa 1-Oct-19 0:21am View
thank you for reply please how that done I need only understand if cannot be add header from browser how website work it actually will see result from browser when he open it
can you give me more details if possible
ahmed_sa 21-Sep-19 22:13pm View
the problem on statement above not return select statement inner join another table
but if i run with one table it will work
can you help me to get select statement
select FooterTable.ItemCode,FooterTable.Quantity,FooterTable.UniPrice from

MasterTable inner join FooterTable on MasterTable.Serial=FooterTable.Serial,MasterTable.BranchCode=FooterTable.BranchCode,MasterTable.Year=FooterTable.Year

where MasterTable.Serial=10 AND MasterTable.Year=2019 AND MasterTable.BranchCode=1
from csharp function getselectstatment
ahmed_sa 21-Sep-19 8:40am View
this is good i make json to fill grid and i need to convert it to json
private static void FillGrids(Control.ControlCollection Controls, xForm frm)

foreach (Control co in Controls)
if (co is xDataGrid && (!String.IsNullOrEmpty(((xDataGrid)co).TableName) || !String.IsNullOrEmpty(((xDataGrid)co).SelectQuery)))
Binder.DataToGrid(frm.Controls, frm, (xDataGrid)co);

if (co.Controls.Count > 0 && co.Name != "pnlGridPanel" && co.Name != "pnlMasterDetailsGrid")
FillGrids(co.Controls, frm);

public static void DataToGrid(Control.ControlCollection Controls, xForm frm, xDataGrid Grid)

string SQL = "";

string Criteria = "";
DataTable Relations = new DataTable();

if (Grid.SelectQuery != "")

SQL = Grid.SelectQuery;
else xExceptions.DataGirdTableNameOrSelectQueryIsMissing();

Relations = DataAccess.ExecuteDataTable(SqlFactory.Queries.Tables_GetRelations(frm.TableName, Grid.TableName));

if (Grid.SelectQuery.IndexOf(" WHERE ", StringComparison.OrdinalIgnoreCase) == -1)
Criteria = SqlFactory.Queries.GetGlobalCriteriaForGrid(frm, Grid.TableName, Relations);
SQL += " WHERE ";
SQL += Criteria != "" ? Criteria : " 1 = 1 ";

Criteria = SqlFactory.Queries.GetGlobalCriteriaForGrid(frm, Grid.TableName, Relations, false);
if (Criteria != "") SQL += " AND " + Criteria;

if (!String.IsNullOrEmpty(Grid.Filter) && !SQL.Contains(" 1 = 1 ")) SQL += " AND " + Grid.Filter;

DataTable dt = DataAccess.ExecuteDataTable(SQL);

if (frm.IsSaveAndCopy)
Grid.ChangeAllRowsState(RowStates.Inserted); //Because of F6
// show data as Grid.datasource=dt;


ahmed_sa 21-Sep-19 5:26am View
are my json string wrong
ahmed_sa 21-Sep-19 4:20am View
Are json is suitable to my case or must change it please help me
ahmed_sa 21-Sep-19 4:12am View
see I modified json to be valid on main thread
ahmed_sa 21-Sep-19 3:46am View
this is not valid can you help me to be valid
ahmed_sa 21-Sep-19 3:21am View
Are my json above is correct or what
ahmed_sa 19-Sep-19 10:21am View
from debug i check my code if if (AccessTokenValue == "1234") is true it must print on browser valid value but it not make that it print invalid value
why that happen
from post man it give me valid value as correct result to my code
can you please help me really it strange problem
ahmed_sa 19-Sep-19 10:16am View
what i meed to ask why data reponse not show when call next on custom middleware
ahmed_sa 17-Sep-19 21:38pm View
can you give me more details about your answer please
ahmed_sa 17-Sep-19 21:33pm View
thank you for reply this mean that I have problem on my app or this not problem
ahmed_sa 7-Sep-19 9:34am View
Are this code add user id to payload
see modified code
public string GenerateTokens(string userId)

var Claims = new Claim[]
new Claim(JwtRegisteredClaimNames.Sub,userId)
var signingkey = new SymmetricSecurityKey(Encoding.UTF8.GetBytes("this is secret phrase"));
var SigningCredntials = new SigningCredentials(signingkey, SecurityAlgorithms.HmacSha256);
var Jwt = new JwtSecurityToken();
var jsonu = new { id = userId };
Jwt.Payload["user"] = jsonu;
return new JwtSecurityTokenHandler().WriteToken(Jwt);
ahmed_sa 7-Sep-19 8:53am View
thank you for reply can you make reply by details if possible this is actually what
i need to complete what you write by make example as reply
can you clear that ( you can have your payload as a json object and you can use claims object to modify the page.)
ahmed_sa 7-Sep-19 8:15am View
OK thanks
ahmed_sa 7-Sep-19 8:14am View
thank you for reply on jwt there are thing name payload
but i dont know how to use it
or how to implement it
ahmed_sa 6-Sep-19 22:54pm View
i will ask you again can you show me psudo code please i don following steps
1- create table loginattempt UserId,TimeStamp,success
2- select * from loginattempt where userid=@userid order by timestamp
what i do after that please ?
ahmed_sa 2-Sep-19 8:04am View
can any one help me
ahmed_sa 2-Sep-19 4:15am View
You can then monitor failures with a simple SELECT from your DB on a user-by-user basis.
ahmed_sa 2-Sep-19 3:59am View
can you give me more details if possible please ?
ahmed_sa 31-Aug-19 6:52am View
all links not related to my topic i posted can you please any one help me
ahmed_sa 31-Aug-19 6:52am View
all links not related to my topic i posted can you please any one help me
ahmed_sa 18-Aug-19 23:24pm View
Thank you very much for help and support when i execute it
No mapping exists from object type Newtonsoft.Json.Linq.JValue to a known managed provider native type
so that how to solve that error please ?
ahmed_sa 15-Aug-19 3:33am View
can you give me sample code or links about that please or you can applying to json file above if possible
ahmed_sa 14-Aug-19 16:19pm View
can you please write all function after you put your modification
ahmed_sa 14-Aug-19 15:42pm View
how i do that
ahmed_sa 14-Aug-19 15:20pm View
meaning how to solve this error or how to modify function to remove this error
ahmed_sa 14-Aug-19 15:18pm View
thank you for reply what i need is to get parameters as return of function
can you help me on any way i will accept
ahmed_sa 13-Aug-19 9:13am View
sql server 2012
ahmed_sa 13-Aug-19 7:24am View
OK this is very good can you please if possible modify code above with paramterized query
i ask and read on google that prevent SQL injection so that can you modify or tell me what i modify in query above to make it paramterized query
ahmed_sa 10-Jul-19 16:12pm View
and when routing can i replace action with this method showtext or not ?
ahmed_sa 7-May-19 0:37am View
can you give me more clear or write psudo code for that please
ahmed_sa 16-Apr-19 7:16am View
please leave all that above my question as following
i open new query sql server 2014 i write query as following
SELECT * from cardsdatavalue Where 1=1 and dbo.CardReceived.Year = '2019' and dbo.CardReceived.ReceivedDate >= '2019-01-01' and CardReceived.ReceivedDate <= '2019-04-16'
Are there are any way to get result of data without changing on where condition table name
ahmed_sa 16-Apr-19 7:06am View
i need to change on view to prevent error display on exe program that only what i need
are this possible i read on internet that i can change order of table on view to prevent error diplsy but i dont know how ?
ahmed_sa 3-Apr-19 17:08pm View
thank you very much in my case i do as following
(x => x.DateTimeRecord < DateTime.Now)
DateTimeRecord is string
How to convert it to datetime
ahmed_sa 3-Apr-19 5:43am View
can you please help me
ahmed_sa 3-Apr-19 5:43am View
result show to me is all records for log of machine
ahmed_sa 11-Mar-19 12:21pm View
ahmed_sa 11-Mar-19 12:21pm View
public List<string> GetColumnNames(string tablename)
var columnNames = _context.Model.FindEntityType(typeof(T))
.GetProperties().Select(x => x.Relational().ColumnName).ToList();
return columnNames;
ahmed_sa 11-Mar-19 12:19pm View
public List<string> GetColumnNames(string tablename)
ahmed_sa 10-Mar-19 12:14pm View
my function structure as above
ahmed_sa 10-Mar-19 12:13pm View
how to do that by entity framework core 2.1
ahmed_sa 10-Mar-19 12:07pm View
i know that but cannot do that by entityframework core 2.1
so that how to do that by cshap
ahmed_sa 18-Feb-19 6:27am View
still not working
ahmed_sa 18-Feb-19 6:26am View
thank you for reply
i modified post but not also working
ahmed_sa 17-Feb-19 2:42am View
or nwhat
ahmed_sa 17-Feb-19 2:41am View
and no need to using array
ahmed_sa 15-Feb-19 20:46pm View
and first create function get type that return max record + 1
are this function also will done on web API
if must
How to write it please
ahmed_sa 15-Feb-19 20:41pm View
only one question i make this as web api to connect to angular on client side
so that are create method get must be written in web api or can done from front end
ahmed_sa 13-Feb-19 18:53pm View
OK thank you it worked
ahmed_sa 31-Jan-19 20:48pm View
if possible can you help me on draw image
ahmed_sa 31-Jan-19 20:47pm View
i try but give me error
ahmed_sa 31-Jan-19 20:47pm View
if (i == 3)
g.DrawImage(row[i].ToString(), font, brush, x + xPadding, y + 5);


g.DrawString(row[i].ToString(), font, brush, x + xPadding, y + 5);
ahmed_sa 31-Jan-19 20:43pm View
can you please if possible show me modified code please
ahmed_sa 31-Jan-19 19:28pm View
please can any one help me
ahmed_sa 26-Jan-19 8:37am View
can any one help me please ?
I need to pass composit key to get by id
but also i have some tables have one key
so what i do please
ahmed_sa 22-Jan-19 18:59pm View
show null on saleheader object
ahmed_sa 22-Jan-19 18:58pm View
public IActionResult Create([FromBody]SalesHeader saleheader)
if i put breakpoint here when click save button
it show to me null
it must have one record in header
and two rows on footer
ahmed_sa 18-Jan-19 21:46pm View
Models as below
Sales Header Model
public int SalesOrderNo { get; set; }
public int SalesYear { get; set; }
public int BranchCode { get; set; }
public int SalesType { get; set; }
public DateTime SalesDate { get; set; }
public int CustomerID { get; set; }
public Customer Customers { get; set; }
public ICollection<SalesFooter> SalesFooters { get; set; }

Sales Footer model
public int SalesOrderNo { get; set; }
public int SalesLineNo { get; set; }
public int SalesType { get; set; }
public int BranchCode { get; set; }
public string ItemCode { get; set; }
public decimal Quantity { get; set; }
public decimal UnitPrice { get; set; }
public decimal Total { get; set; }
public Items Itemes { get; set; }
public SalesHeader SaleHeaders { get; set; }
ahmed_sa 17-Jan-19 18:44pm View
thank you for reply
and what about properties of sales footer hot to get them
ahmed_sa 17-Jan-19 10:45am View
public class EmployeeController : Controller
private IrepositoryTab<employee> _repository = null;
public EmployeeController(RepositoryTab<employee> emp)
this._repository = emp;
public IActionResult Index()
var employees = _repository.GetAll();
return View(employees);
ahmed_sa 7-Jan-19 15:19pm View
and id =2
ahmed_sa 7-Jan-19 15:19pm View
nextID variable when put break point it have null value
ahmed_sa 7-Jan-19 15:04pm View
this is full code for my controller employee
this is all my code
using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
using Microsoft.AspNetCore.Mvc;
using Microsoft.AspNetCore.Mvc.Rendering;
using Microsoft.EntityFrameworkCore;
using TAB.Data;
using TAB.Data.Dto;
using TAB.Service;

namespace TAB.Web.Controllers
public class EmployeesController : Controller
private readonly IEmployees _context;

public EmployeesController(IEmployees context)
_context = context;

// GET: Employees/Create
public IActionResult Create()
var model = new Employee();
model.EmployeeId = _context.GetAll().Max(Employee => Employee.EmployeeId) + 1;

return View(model);

public ActionResult Next(int id)
var nextID = _context.GetAll().OrderBy(i => i.EmployeeId)
.SkipWhile(i => i.EmployeeId != id)
.Select(i => i.EmployeeId);

ViewBag.NextID = nextID;

return View("Create");

public async Task<iactionresult> Create(Employee employee)
if (ModelState.IsValid)

if (employee.EmployeeId <= 0)
await _context.InsertAsync(employee);

await _context.UpdateAsync(employee);

return RedirectToAction("Index");

return View(employee);


ahmed_sa 7-Jan-19 14:33pm View
so that how to solve problem can you tell me
ahmed_sa 6-Jan-19 15:18pm View
thank you for reply
this is meaning make action for every next,prev,first,last
ahmed_sa 29-Dec-18 4:32am View
please can mehrdadeahady give me more clear for your nswer please
ahmed_sa 29-Dec-18 4:26am View
thank you for reply
i already do as you tell me
but no answer
ahmed_sa 29-Dec-18 2:35am View
thank you for reply
can you please if possible give me details for that
ahmed_sa 29-Dec-18 2:34am View
thank you for reply
can you please if possible give me details for that
i posted again because i dont understand first post answer
i write under first post about details but no given answer for me
please any on give me more details
ahmed_sa 25-Dec-18 3:05am View
thank you for reply
can you give me more details if possible please
i need to make that but cannot so if you can give me more details please
ahmed_sa 16-Dec-18 20:25pm View
NOT selecting milion rows
ahmed_sa 28-Sep-18 10:43am View
can you help me by solving this problem by any source code by jquery
ahmed_sa 28-Sep-18 10:11am View
ahmed_sa 16-Sep-18 22:32pm View
select BranchCode,UnitCode,RequiredAmount, Serial,Year,Month,CurrentReadingDate,CurrentMeterReading,LastMeterReading,CurrentConsumption,CurrentConsumptionValue ,VATValue,CleaningFees
select BranchCode,UnitCode,RequiredAmount, Serial,Year,Month,CurrentReadingDate,Convert(varchar,CurrentMeterReading) as CurrentMeterReading,Convert(varchar,LastMeterReading) as LastMeterReading
,Convert(varchar,CurrentConsumption) as CurrentConsumption,Convert(varchar,CurrentConsumptionValue) as CurrentConsumptionValue ,Convert(varchar,VATValue) as VATValue,
Convert(varchar,CleaningFees) as CleaningFees from WAHInvoice invo where 1=1 AND year=2018 AND BranchCode = 1/* and Month=5 and UnitCode=5639*/
SELECT VTargetDetail.BranchCode ,VTargetDetail.SubLdgCode as UnitCode ,
(SUM(dbo.VTargetDetail.Debit * dbo.VTargetDetail.CurrencyRate) - SUM(dbo.VTargetDetail.Credit * dbo.VTargetDetail.CurrencyRate) ) as Balance ,'' AS Serial ,'' as YEAR,'' AS Month,'' as CurrentReadingDate,'' as CurrentMeterReading,'' as LastMeterReading,'' as CurrentConsumption,'' as CurrentConsumptionValue,'' as VATValue,'' as CleaningFees
dbo.TypeTrxSafe ON dbo.VTargetDetail.BranchCode = dbo.TypeTrxSafe.BranchCode AND dbo.VTargetDetail.TrxTypeCode = dbo.TypeTrxSafe.SafeTrxTypeCode
WHERE (1 = 1) AND (VTargetDetail.TrxDate <= '2018/09/17') AND (VTargetDetail.SubLdgCodeType = 28) /*AND (VTargetDetail.SubLdgCode = 5639) */
group by VTargetDetail.SubLdgCode,VTargetDetail.BranchCode
)as INV where Month=5 and UnitCode=5639
my question how to select Balance alias from inside union
ahmed_sa 11-Sep-18 10:25am View
if windows form event why i ask about that i need way or debug tool can by that know what order of events execution
ahmed_sa 11-Sep-18 10:22am View
this is not windows form events if windows forms event i can get but these custom
events like another load,anotherload with values like that i cannot guess what this do it
ahmed_sa 10-Sep-18 23:00pm View
Thank you for reply
but how to prevent duplicate on digit from code can you tell me by details please help me
and can you give me link or more explain to your idea nay be if applicable i will implement it
ahmed_sa 12-Feb-18 18:19pm View
OK but this way above when i use it
ahmed_sa 29-Jan-18 18:26pm View
sorry i use windows form not web form
can you please modify function above for windows form if possible
ahmed_sa 7-Jul-17 12:24pm View
this is explain to what i need
I need to design database for booking tours for tourism company

Tourist booking package have two type :

Reservation hotel : this is will by 4 days or 6 days .

Suppose he select hotel Hilton 4 days meaning 3 Nights include ( accommodation costs + flight costs + transfer costs )

Reservation Program: this will be 4 days or 6 days only

Suppose he select program alexa 4 days meaning 3 Nights ( accommodation costs + flight costs + transfer costs + excursions costs)

Accommodation cost include room price per days + services depend on periods

Meaning room price from 01/01/2017 to 01/04/2017 different from 01/05/2017 to 01/09/2017

Flight include internal flights and return back to his country

Transfer : include internal transfer from airport to hotel .

Price of transfers from date 01/01/2017 to 01/04/2017 different from 02/04/2017 to 02/12/2017

Excursions : visit musumes like that and this is represent cost of visit

Excursion price depend on periods .

Price of excursion from date 01/01/2017 to 01/04/2017 different from 02/04/2017 to 02/12/2017

And excursion only found on programs not hotel reservation

8 days for hotel or program start from flight date

Every flight have more than one package (reservation hotel or program)

Final Result as below :

Package 1 4 days
day flight hotel
day1 amsterdam to aswan Hilton
day2 Hilton
day3 Hilton
day4 aswan to amsterdam
Package 1 4 days costs(Here actually my problem )
day flightcosts hotelcosts
26/07/2017 500 50
27/07/2017 50
28/07/2017 50
29/07/2017 500
ahmed_sa 7-Jul-17 12:10pm View
in relation above exist in image i have relation one to many between hotel and package
and in same time relation between day details table and hotel are this relation is correct or wrong
ahmed_sa 7-Jul-17 12:05pm View
relation is true or circular
ahmed_sa 27-Jun-17 21:01pm View
i will not repost again but please can any one help me in that if possible
ahmed_sa 27-Jun-17 20:59pm View
ok i need to how to insert cost from flight and hotel in table cost duration
ahmed_sa 25-Jun-17 18:00pm View
can any one help me in that problem please
ahmed_sa 22-May-17 15:58pm View
Thank you for reply
only one question by using identity i can create users in external database or inside project only
ahmed_sa 8-May-17 4:24am View
are there are any way to create files data matrix barcode without using save
if there are please tell me
because i dont know
ahmed_sa 8-May-17 4:21am View
I dont need to print matrix barcode in few seconds i need to print more quickly
example in my code i generate 200000 in 20 minutes
I need to generate 200000 data matrix files in 5 minutes
ahmed_sa 7-May-17 18:36pm View
so that please if possible how to write .save function
root + "\\" + Serial + ".emf" for more speed and performance
please any one can answer for me
ahmed_sa 7-May-17 10:14am View
can any one reply for me in comment to clear what i need
ahmed_sa 7-May-17 10:11am View
this is not for user this is for pharmaceutical company need to print barcode on pakages of medicin
ahmed_sa 7-May-17 10:11am View
I asking if there are any thing can do my generating faster
ahmed_sa 28-Apr-17 8:10am View
what i search in google can you give me title or links or articles or code
ahmed_sa 28-Apr-17 8:10am View
can you give me links explain that with mvc
and i will search for that please
ahmed_sa 27-Apr-17 11:47am View
the error happen in this line
string ret = comm.ExecuteScalar().ToString();
ahmed_sa 30-Mar-17 6:55am View
if i need it dynamically in textbox
my secnario as following
textbox have values 1002,1991,2007,3006
so that how to select these values
ahmed_sa 8-Mar-17 11:19am View
OK thank you for reply
thank you very much for help
ahmed_sa 8-Mar-17 10:54am View
this meaning correct or not only one answer
ahmed_sa 8-Mar-17 10:53am View
yes i click in access
ahmed_sa 8-Mar-17 10:24am View
can you help me please
ahmed_sa 8-Mar-17 10:13am View
it show on filed qrimg long binary data
so that what this are this correct added or wrong
it not open when click
ahmed_sa 8-Mar-17 10:11am View
I CHANGE code to
//byte[] buffer = File.ReadAllBytes(path);
byte[] buffer= ImageToBytes(pictureBox1.Image, ImageFormat.Jpeg);

OleDbConnection oleDbConnection = new OleDbConnection(connection);
string str = "Update AllPrinting set qrimg=@qrimg where UserID=@UserID";
OleDbCommand oleDbCommand = new OleDbCommand();
oleDbCommand.Connection = oleDbConnection;
oleDbCommand.CommandText = str;
OleDbParameter param = new OleDbParameter();
param.OleDbType = OleDbType.Binary;
param.ParameterName = "qrimg";
param.Value = buffer;
OleDbParameter param2 = new OleDbParameter();
param2.OleDbType = OleDbType.VarChar;
param2.ParameterName = "UserID";
param2.Value = label4.Text;
// oleDbCommand.Parameters.AddWithValue("@UserID", label4.Text);

// oleDbCommand.Parameters.AddWithValue("@qrimg", buffer);
using (oleDbConnection)


catch (Exception ex)
it update qrimg field but it display as
below screen shoot
ahmed_sa 8-Mar-17 9:44am View
how i do that i check from database nothing property with this name
ahmed_sa 8-Mar-17 9:11am View
i use buffer in place of yourphoto not working
ahmed_sa 8-Mar-17 9:10am View
not working
ahmed_sa 8-Mar-17 9:00am View
check debugger screen shoot
ahmed_sa 8-Mar-17 8:52am View
image not empty i check
image have data because i show on report after add data
ahmed_sa 8-Mar-17 8:41am View
buffer is null
ahmed_sa 8-Mar-17 8:41am View
I check buffer is null in debugger but path have value of image bath
what i do now
ahmed_sa 8-Mar-17 8:36am View
it is screen shoot
ahmed_sa 8-Mar-17 8:36am View
above link to my table in access database
ahmed_sa 8-Mar-17 8:35am View
ahmed_sa 8-Mar-17 8:32am View
yes i check it empty
ahmed_sa 8-Mar-17 8:24am View
i make catch it not give me any error
please help me
ahmed_sa 8-Mar-17 8:18am View
what type Blob i dont have type blob i set qrimg column to datatype oleobject
also these two columns exist in table AllPrinting
ahmed_sa 8-Mar-17 8:03am View
i do as below but update not happen
please help me
byte[] buffer = File.ReadAllBytes(path);

OleDbConnection oleDbConnection = new OleDbConnection(connection);
string str = "Update AllPrinting set qrimg=@qrimg where UserID=@UserID";
OleDbCommand oleDbCommand = new OleDbCommand();
oleDbCommand.Connection = oleDbConnection;
oleDbCommand.CommandText = str;
oleDbCommand.Parameters.AddWithValue("@UserID", label4.Text);
byte[] yourPhoto = buffer;
oleDbCommand.Parameters.AddWithValue("@qrimg", yourPhoto);
using (oleDbConnection)


ahmed_sa 7-Mar-17 9:01am View
thank you for reply
this is add image to excel but not insert as field with id and name and country
ahmed_sa 7-Mar-17 9:00am View
thank you for reply
this is add image to excel but not insert based on condition
ahmed_sa 7-Mar-17 8:44am View
can you give me any trick to solve proble
actually i need to add image in excel to show on report rdlc
can you tell me what i do to solve that problem
ahmed_sa 7-Mar-17 8:40am View
so that what i do to solve my problem
i can accept any solution
ahmed_sa 6-Mar-17 18:40pm View
to clear what i need controls that be hidden in rdlc leave space when hidden
and this space another controls that display occupy this space
how to prevent occupy another controls to place of hidden controls
this is actually what i need
ahmed_sa 28-Feb-17 5:34am View
if i set in my connection IMEX=1 WHAT WHILL HAPPEN
ahmed_sa 28-Feb-17 5:32am View
from what i read my connection above is correct what is benfit from using imex
ahmed_sa 26-Feb-17 10:52am View
please help me to more explain what i need is to
to more explain
suppose i need to do action after 10 second

i write in textbox1 Michel

counter of timer will counting 0,1,2,3,4,5,6

in second no 6

i change text box to martin

timer will execute after 4 second

but what i need is to starting from second 0 in the moment i changed text box
ahmed_sa 26-Feb-17 9:17am View
can you please tell me how to represent Timer_Tick event in code
ahmed_sa 24-Feb-17 11:00am View
what i change to my code according to result i get from hex viewer
ahmed_sa 24-Feb-17 10:59am View
so that what i do now please help me
ahmed_sa 24-Feb-17 10:38am View
ahmed_sa 24-Feb-17 10:32am View
i open file and scan qr and read data by scanner to this file after that install hex viewer and open file scanned or readed data to it i get values but i dont know what separator or break so that what i do
ahmed_sa 24-Feb-17 7:19am View
so that how loaded the data into a HexViewer?
ahmed_sa 6-Feb-17 10:40am View
I get error when trying Items collection cannot be modified when the datasource property is set error if possible can any one help me
ahmed_sa 14-Jan-17 7:46am View
OK Now if i build web site by using mvc what i select suppose i have 50 tables what i select to work entity framework or code first
ahmed_sa 31-Dec-16 8:27am View
yes i need to convert to binary string 0 or 1 and show it in text box
ahmed_sa 31-Dec-16 6:22am View
I need to convert image from byte array to binary string 0 or 1