|
HII have a column whose datatype is medium time (i.e hh:mm AM/PM) and i want to retireve taht into my datagrid...
its coming with the date ....
can some on ehelp how i must set the date formatting expression so that the time somes as hh:mm AM/PM
thank u
hepsy
|
|
|
|
|
The format string you put in your column would be "hh:mm tt" .
|
|
|
|
|
thanks dave ..
but i get an error......
for the time to appear as MM/dd/yyyy i wrote the bound column in the datagrid as
Text='<%# DataBinder.Eval(Container, "DataItem.event_date", "{0:MM/dd/yyyy}") %>'
how should i write so that i get the tome in hh:mm AM/PM format...
my datatype in the table is as time or medium time but in the datagrid it is coming as whole datetime....
can u please help...........
thank u
hepsy
|
|
|
|
|
Hi thank u ..
i got it
i wrote it like this
"{0:hh:mm tt}" and its working perfectly
thank u
hepsy
|
|
|
|
|
plz help me in designing a sample dictionary in my own language.
Is it a simple database project where the laxicon file is the data base of words.or any thing else?
|
|
|
|
|
I think I had this assignment at uni a long time ago...
Start with a collection of words. Get someone to enter a word. Check your collection - if the word isn't there, prompt to add the word to the dictionary. If the word is there, let them know it's found. Simple.
-------------------------------------------
Don't walk in front of me, I may not follow;
Don't walk behind me, I may not lead;
Just bugger off and leave me alone!!
|
|
|
|
|
ThanX for ur responce.
can you tell me,how i'll develop the collection of words.Is this a separate file.As in data base project the data base file(eg in MS Access).
how i'll make that file.i mean what i need to develop that file.
please help me.
|
|
|
|
|
Hello,
I have created one Image Uploader application which uploads jpg images to specified server. What i am doing is Reading the File Content in binary and add http header then send the file content and http header throgh http request. currently i am using Winsock control to send the request. It works fine in English OS(XP) but when try to upload from chinese OS(XP) it upload the image and shows that upload sucess but the uploaded image is get currupted, its file size is reduced and when i try to see the property of the uploaded image, it shows that the Type and Size property are missing. I am using MIME type as "image/jpeg" in http header. i also try to send the request through Internet Explorer Control, but problem remain same. can anybody suggest what is the problem? is problem in reading file or anything else???
I try to use charset as utf-8 in http header, also try to send data in byte array instead of string but still problem remain same..
|
|
|
|
|
Without seeing the code you're using to put this upload together, it's impossible to tell you anything about what might be wrong.
If this is an ASP.NET app, why aren't you using the FileUpload control??
|
|
|
|
|
Hello guyz,
anyone know any safe way to protect our source code from hacker?
hacker can convert EXE file to its source code files it make me worry .
anyone know about it?
....
Can't say anything
.....
|
|
|
|
|
Thats a great wonder.. how to convert EXE/DLL file into source code?
I have never listen that it is possible to convert machine code into human language.
|
|
|
|
|
There are disassemblers for Managed Code. I think he is asking regarding that. Isn't it?
|
|
|
|
|
Good question.
My first answer would be a question - why would anyone want to convert your exe/dll code given how difficult this is to do(see below)?
The answer is yes it is possible to decode an exe/dll from .NET
This is because .NET is machine independent.
What this means is that when you compile your code the exe produced is in CIL format (Common intermediate language).
When the code is run the exe is compiled properly for the machine so that it runs optimally on that particular machine. This is called JIT (just in time compilation)and is performed by the jitter - so I guess having lots of programs running wil give your computer the jitters
The .Net framework basically compiles a second time at runtime even though you thought you had already compiled the code.
There is a program which can decode an exe - however I imagine the result is rather difficult to read.
Strangely enough I was reading about this last night so it is still fresh on my mind.
I hope this is of help
You always pass failure on the way to success.
|
|
|
|
|
In the real world, this is very unlikely to happen IMO. You can buy an obsfucator if you want.
Christian Graus - Microsoft MVP - C++
"I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
|
|
|
|
|
Hi, I have develop an application in vb2005. some part of my application contain numeric up down control. i want to prevent the user from typing in that control and just allow them to use the up down arrow only. I try to set the code in keypress event e.handle=true but the user can use the delete key to delete value. Finally what i want is totally prevent the user from typing anything in this numeric up down control. Thank in advance!!!
|
|
|
|
|
Use a label for your control instead of a text box. Then when the user clicks the up/down arrow, update the text/caption of the label.
-------------------------------------------
Don't walk in front of me, I may not follow;
Don't walk behind me, I may not lead;
Just bugger off and leave me alone!!
|
|
|
|
|
_Damian S_ wrote: Use a label for your control instead of a text box
How could i use a label control instead of the text box? because when i drag this numeric up down control on the form, it already display a textbox with an arrow key.
|
|
|
|
|
Ah... I thought you were writing your own custom control using a text box and two buttons...
-------------------------------------------
Don't walk in front of me, I may not follow;
Don't walk behind me, I may not lead;
Just bugger off and leave me alone!!
|
|
|
|
|
No, I didn't develop my own control. This control is the built in control in vb2005. Do you have any other idea to the question that I asked in the previous message?
|
|
|
|
|
There's no way to do it in the stock control. You'd have to "roll your own" to get this kind of functionality.
|
|
|
|
|
I have been given the following spec.
Task: Create a Database access class for your project. This class represents middle tier (business logic) that access a database.
Deliverable:
* Create a method that returns a datareader. This method should take a SQL statement (select * from person). The method itself should do everything else. Return the datareader. You can instantiate this class and assign it to the datasource just before the data bind like this:
dg1.datasource=myDBClass.getDataReader("Select * from person")
* Create a method that returns a dataset. Remember that the dataset can hold multiple tables. So for this method you should be able to either pass it an array of select statements or be able to call the method more than once. In either case, you will need a SQL statement, the dataset you want to populate, and what you want to call the table in the dataset.
* Create a method that returns a true or false after attempt to before an update, insert, or delete. Each of these items do not return a resultset; therefore, use a try/catch block to see if it completes.
I have only been programming in vb for about 2 1/2 weeks, so this has me riddled. Can someone help, or at least point me in the right direction. Are there any examples on Code Project?
Thanks,
|
|
|
|
|
ddtayl06 wrote: I have only been programming in vb for about 2 1/2 weeks
Pretty advanced task requirement for someone with only 2 1/2 weeks programming experience. Homework project, I suspect?
"Try asking what you want to know, rather than asking a question whose answer you know." - Christian Graus
|
|
|
|
|
This doesn't pass the "sniff test" for homework. 2.5 weeks of "class" and you've been given this assignment?? I don't think so.
Though this is very easy to put together, given a short breakdown of the problem.
You're writing a Method that returns a DataReader. This method will take an SQL statement as a String argument.
You're writing another method that takes three arguments, an SQL statement, a DataSet, and a name for a table in that DataSet.
The first sentance in the third point makes no sense.
|
|
|
|
|
I've created and compliled an assembly from a text string using vbcodeprovider and am able to get the results back from it. But I'm missing something critical -- how do I pass data from my running program to that assembly? I'd like to pass for instance a couple of arrays that the code in the assembly will modify.
Thanks as always!
|
|
|
|
|
Oh, sorry, I think you have to compile the assembly and then run it, passing the parameter(s) to it on the run.
|
|
|
|