|
Hello.
In the database tree structure of how to write?
After the move in the C#
|
|
|
|
|
Can you please give some detail, so that it is easier to answer your question.
And please don't cross post. Read this[^] guideline before you post your question.
HTH
Jinal Desai - LIVE
Experience is mother of sage....
|
|
|
|
|
Hi,
I am building a GPS assisted application, which is to display a weather forecast for the closest location with reference to current location.
I am using yahoo weather forecasts.
What i have done:
1. I can successfully request a weather for a place if i know its WOEID (Note: only some places have weather forecasts).
2. In order to get a WOEID of the current location i can query "FLICKR" using YQL and passing current latitude and longitude and get a WOEID back for that place.
Problem:
Is there any way i can request a weather forecast for a nearest location to acquired WOEID of current location.
Thank you in advance,
|
|
|
|
|
Hi Guys,
I would appreciate it if someone has found/created an MS Word Viewer/Editor Control on Visual Studio.
Thanks,
|
|
|
|
|
If you are looking for a word .doc editor in C#, you can find several on the internet. See here.
My signature "sucks" today
|
|
|
|
|
Hey guys, I'm having trouble searching for a date I fetch in C# in my database
in my application the date time value is in this format: 6/16/2010 9:41:19 AM in the database I use
CONVERT(VARCHAR(10),SR.StuDateOfReg,101) to convert my date and extract only the date part but what I get is 06/15/2010.
I thought there should be no difference between 6/16/2010 and 06/16/2010,
when I execute this query
... WHERE CONVERT(VARCHAR(10),SR.StuDateOfReg,101) >= CONVERT(VARCHAR(10),'6/15/2010',101)
I don't get anything back but when I go for
... WHERE CONVERT(VARCHAR(10),SR.StuDateOfReg,101) >= CONVERT(VARCHAR(10),'06/15/2010',101)
It works!
so how can I change one to another?
regards,
|
|
|
|
|
Found it myself
I used this function:
CREATE FUNCTION dbo.fnFormatDate (@Datetime DATETIME, @FormatMask VARCHAR(32))
RETURNS VARCHAR(32)
AS
BEGIN
DECLARE @StringDate VARCHAR(32)
SET @StringDate = @FormatMask
IF (CHARINDEX ('YYYY',@StringDate) > 0)
SET @StringDate = REPLACE(@StringDate, 'YYYY', DATENAME(YY, @Datetime))
IF (CHARINDEX ('YY',@StringDate) > 0)
SET @StringDate = REPLACE(@StringDate, 'YY', RIGHT(DATENAME(YY, @Datetime),2))
IF (CHARINDEX ('Month',@StringDate) > 0)
SET @StringDate = REPLACE(@StringDate, 'Month', DATENAME(MM, @Datetime))
IF (CHARINDEX ('MON',@StringDate COLLATE SQL_Latin1_General_CP1_CS_AS)>0)
SET @StringDate = REPLACE(@StringDate, 'MON',
LEFT(UPPER(DATENAME(MM, @Datetime)),3))
IF (CHARINDEX ('Mon',@StringDate) > 0)
SET @StringDate = REPLACE(@StringDate, 'Mon', LEFT(DATENAME(MM, @Datetime),3))
IF (CHARINDEX ('MM',@StringDate) > 0)
SET @StringDate = REPLACE(@StringDate, 'MM',
RIGHT('0'+CONVERT(VARCHAR,DATEPART(MM, @Datetime)),2))
IF (CHARINDEX ('M',@StringDate) > 0)
SET @StringDate = REPLACE(@StringDate, 'M',
CONVERT(VARCHAR,DATEPART(MM, @Datetime)))
IF (CHARINDEX ('DD',@StringDate) > 0)
SET @StringDate = REPLACE(@StringDate, 'DD',
RIGHT('0'+DATENAME(DD, @Datetime),2))
IF (CHARINDEX ('D',@StringDate) > 0)
SET @StringDate = REPLACE(@StringDate, 'D', DATENAME(DD, @Datetime))
RETURN @StringDate
END
dbo.fnFormatDate (SR.StuDateOfReg, 'M/DD/YYYY') >> 6/15/2010
|
|
|
|
|
That's not a good design. Change the data type for your date time values to 'datetime'. Furthermore, use parameterized queries. Then your problems should be easily resolved without long functions.
|
|
|
|
|
That is horrible. Don't use strings for dates (or numbers); it's terribly inefficient, especially when you convert the data in the table to strings and then compare -- don't do it!
Convert the incoming string to a date and then compare.
|
|
|
|
|
i want to move a button on a form with a keypress on keyboard.
please help me
what should i do?
danialkhazaei@yahoo.com
|
|
|
|
|
i want to move a button on a form with a keypress on keyboard.
please help me
what should i do?
|
|
|
|
|
1) You have posted the same question twice. Remove the one that has not been answered to.
2) You have used the joke icon while posting this question. People will not take your question seriously.
3) See here - maybe this can help.
My signature "sucks" today
|
|
|
|
|
Set the KeyPreview of the containing form to true , handle the Form 's KeyPress /KeyDown /KeyUp event depending on your needs and set the Button 's Location property to the point you want.
Please only post once and give your post a title that indicates the problem in future.
DaveIf this helped, please vote & accept answer!
Binging is like googling, it just feels dirtier. (Pete O'Hanlon)
BTW, in software, hope and pray is not a viable strategy. (Luc Pattyn)
|
|
|
|
|
Hi mehdi
Post your questions with proper subbject
thanks
Life's Like a mirror. Smile at it & it smiles back at you.- P Pilgrim
So Smile Please
|
|
|
|
|
Delete the second copy of your question, before it gets replied to.
Never post your email to any forum - unless you really like spam! CP will send you emails as necessary when people reply to you. (Just like this one)
Did you know:
That by counting the rings on a tree trunk, you can tell how many other trees it has slept with.
|
|
|
|
|
I decided not too use it as a singleton (or in my case as I was being silly a "Global" object !).
Thank's
|
|
|
|
|
venomation wrote: I decided not too use it as a singleton (or in my case as I was being silly a "Global" object !).
Ok. So what are you answering to?
Are you referring to some other article / post?
Then please post that link here or better, post this message within that same article or link.
My signature "sucks" today
|
|
|
|
|
I want to assign 10 threads (it could be n) to a listview of (10000 records).
The listview's first coloumn is email. So I want to send email to a method and get a return string as a result (valid or not). which i want to add to the second column of the listview. Pls help me how to do it?
Code would be much appriciated.
|
|
|
|
|
So you deleted your original post to repost your request for code.... why?
Why is common sense not common?
Never argue with an idiot. They will drag you down to their level where they are an expert.
Sometimes it takes a lot of work to be lazy
Individuality is fine, as long as we do it together - F. Burns
|
|
|
|
|
so he decided to completely ignore forum guidelines, ignore and down-vote my earlier reply, delete the question, create a new thread on the same subject, and use a meaningless subject line. Not a compelling start.
|
|
|
|
|
Well it would appear that I was down voted as well... oh the calamity.
Why is common sense not common?
Never argue with an idiot. They will drag you down to their level where they are an expert.
Sometimes it takes a lot of work to be lazy
Individuality is fine, as long as we do it together - F. Burns
|
|
|
|
|
Wes Aday wrote: oh the calamity
little ones can be cured easily.
|
|
|
|
|
Luc Pattyn wrote: little ones can be cured easily
Only if you believe the SPAM...
Why is common sense not common?
Never argue with an idiot. They will drag you down to their level where they are an expert.
Sometimes it takes a lot of work to be lazy
Individuality is fine, as long as we do it together - F. Burns
|
|
|
|
|
First of all I posted in this forum for the first time.( i know it is a mistake now).
Secondly if my code was working i will not be looking for help. About deleting my code and reposting the question. You only said that it does not look right.
Anyway i will do it myself thanx have a nice day
|
|
|
|
|
People here are more than willing to help out; however there are some rules to make that easier and to get things a bit streamlined. Good luck with those threads.
|
|
|
|