158 Topics

Member Avatar for
Member Avatar for mesbahuk

I have java code that uses Java's `java.util.Timer.schedule()` method. **Method Description:** *The `schedule(TimerTask task,long delay,long period)` method is used to schedule the specified task for repeated fixed-delay execution, beginning after the specified delay.* public void schedule(TimerTask task,long delay,long period)java.util.Timer.schedule() Is there an equivalent method in C#? If NOT, how can …

Member Avatar for Momerath
0
486
Member Avatar for mesbahuk

I have a Java code block like following: Vector<NameAddress> route = dialog.getRoute(); for ( Enumeration<NameAddress> e = route.elements(); e.hasMoreElements(); ) { // some more to copy route to another Vector<> } I am trying to convert it in C# and here is my code: List<NameAddress> route = dialog.getRoute(); for ( …

Member Avatar for C#Jaap
0
298
Member Avatar for Lisabraker
Member Avatar for mesbahuk

In my *Java to C#* Conversion Project, at one point I came to use java's `startsWith(string prefix, int toffset)` method. I used a substring to solve it for C#. Java Code Snippet: String str1 = "one over the coocoo's head"; String str2 = "someone"; System.out.println(str1.startsWith(str2, 4)); C# does not have …

Member Avatar for JoeProgrammer
0
396
Member Avatar for mesbahuk

For my **Java to C#** conversion project, I need to use something equivalent to Java's `Calender` class. I have some codes like: Calender cal = Calender.getInstance(); long time = Calendar.getInstance().getTime().getTime(); long time2 = System.currentTimeMillis(); which returns some random values at different times. I have come to know C-sharp's `DateTime` is …

Member Avatar for ddanbe
0
976
Member Avatar for sw8revenge

i need some help... please help me convert this code into vb .net im using a device w/c is digital persona fingerprint scanner, the code works but it does not show any scanned image of the fingers in vb .net Private Sub cmdCancel_Click() op.Cancel lblMessages.Caption = "Operation canceled" Set op …

Member Avatar for arorastat3456
0
711
Member Avatar for LeNenne

Hi folks I wonder if this code can bee converted to VB6 or there are a simular code. Lenny Dim strMSG As String > strMSG = "This Demo Has Expired" & vbCrLf & "Please Contact Me to Obtain > the Full Version" > > If DCount("[autonumberID]", "app.path/phonetel.mdb") > 20 Or …

Member Avatar for bonzo2008
0
197
Member Avatar for mesbahuk

I have a Java code block like following: public TcpConnection(TcpSocket socket, long alive_time, ITcpConnectionListener listener) { init(socket,alive_time,listener); start(); } For the conversion in C#, When I try to replace the `start()` method with `System.Threading.ThreadStart()`, it gives an error. How can I start a thread in C#?

Member Avatar for ddanbe
0
279
Member Avatar for mesbahuk

I'm currently working in a java to c# conversion project. In one part I got this Java code snippet. public CustomType someMethod(Message msg) throws IOException { byte[] data = msg.toString().getBytes(); } to my understanding, data contains the byte representation of the string *msg.toString()* But when I try to write it …

Member Avatar for mesbahuk
0
262
Member Avatar for mesbahuk

In java this is how a DerivedClass can implement it's BaseClass's constructor. public DerivedClass extends BaseClass { //some properties public DerivedClass(param) { super(param); } } I have learnt C-Sharp's *base()* does the similar thing, but when I replace *super(param)* with *base(param)*, it does not gives what I'm expecting. How can …

Member Avatar for Ketsuekiame
0
265
Member Avatar for mesbahuk

I have been working on a conversion project for last few days where I need to convert a Java library to C#. At one point I came to java's certain feature called [Exceptions Thrown by a Method](http://docs.oracle.com/javase/tutorial/essential/exceptions/declaring.html). Here is a little glimpse of it: public boolean isRequest() throws NullPointerException { …

Member Avatar for Ketsuekiame
0
303
Member Avatar for mesbahuk

In the conversion process of a java to c# project, i have come to java's ***indexOf()*** function in ***string.java*** class, which takes in two integers (int ch, int fromIndex) and return some integer value for a char (i'm guessing its an ASCII value). I need to know if there is …

Member Avatar for mesbahuk
0
652
Member Avatar for mesbahuk

I am currently converting a Java library to C# .Net, please help me to find if there are C# equivalents of the following java specifics: * RuntimeException() * IllegalStateException() * StringBuffer Any resource on Java to C# conversion will be very helpful. Thanks in advance.

Member Avatar for mesbahuk
0
268
Member Avatar for admin-pc
Member Avatar for xanawa

Hi, I encrypted two strings and returns example "euHK5s9h30Q=" then I am trying to convert the string given to GUID Guid tokenGuid = new Guid(encryptionString); and i is giving me ***Guid should contain 32 digits with 4 dashes (xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx).*** error how can i resolve it please?

Member Avatar for Ketsuekiame
0
260
Member Avatar for marvin.gorres.5

Hello guys, i'm new here. I would like to convert my .txt file which have the following content into an array of int which every elemnt in the array should only have 4 character inside. example: two[1]= 0x03; two[2]= 0x00; two[3]= 0x03; two[4]= 0xf5; This is the content of my …

Member Avatar for Ancient Dragon
0
329
Member Avatar for marvin.gorres.5

Hello guys, i'm new here. I would like to convert my .txt file which have the following content into an array of int which every elemnt in the array should only have 4 character inside. example: two[1]= 0x03; two[2]= 0x00; two[3]= 0x03; two[4]= 0xf5; This is the content of my …

Member Avatar for abhi_d_one
0
276
Member Avatar for SLMQC

I am new to VB and working on a homework assignment that I’ve seen posted in years past. The threads were aged a year or more so I’m starting a new discussion. I am writing a program that allows me to enter sales for 5 stores and display a bar …

Member Avatar for tinstaafl
0
330
Member Avatar for anton.yakushin

Here's my problem: - I have a static site with Google Analytics tracking code. - To buy one of my services, users call me, and when their order is ready (many days later), I send them an e-mail link to a special page (download.php) where I have GA tracking code …

Member Avatar for anton.yakushin
0
298
Member Avatar for group256

Hi everyone, I have the implementation for a linked-list based Stack. I believe the entire code is correct, but only the way I call the push and pop function mighe be wrong. Any idea how they should be called? Mine returns garbage: #include <iostream> using namespace std; typedef struct Elements …

Member Avatar for deceptikon
0
280
Member Avatar for venus87

private void decrypt_Click(object sender, EventArgs e) { v = Convert.ToDouble (txtencrypt.Text); t = Math.Pow(v, d); MessageBox.Show(Convert.ToString(t)); MessageBox.Show(""+t.ToString()); MessageBox.Show("" + Convert.ToDecimal(n)); msg = Convert.ToInt16(Math.Pow(v,d) % Convert.ToDouble(n)); txtdecrypt.Text = Convert.ToString(msg); } this is the code im working now for rsa decryption. the problem im getting is the pow function return in exponential …

Member Avatar for ddanbe
0
230
Member Avatar for jakub.peciak

I have a time as a string saved as HoursMinutes example 1642 (16:42) and I tried to convert it to date as Hours:Minutes with following code: Dim dt As Date Dim s As String s = "1642" dt = CDate(Format(s, "00:00")) but the result is: 00:00 instead of 16:42 Any …

Member Avatar for jakub.peciak
0
335
Member Avatar for DaveyMoyes

Hi everyone - I am helping to build a website for a good friend of mine & we are adding into the website an easy to read conversion rate. The only problem we have at the moment is the value is being displayed incorrectly. for instance - If the website …

Member Avatar for DaveyMoyes
0
154
Member Avatar for jetro57070

how do you manually convert a multi digit ascii string into the hex equilavent of a decimal integer with out using a C library function. For instance If I have a small program asking a user to type into the keyboard a decimal number and lets say they type in …

Member Avatar for jetro57070
0
7K
Member Avatar for CodyM

Trying to make my function that takes in an array and arrayLength and outputs a linked list equivalent to the array.Any help would be greatly appreciated! Node* array2List(int A[], int n) { Node* p; Node* q; q = NULL; for(int i = 0;i<n;i++) { p = new Node; p->val = …

Member Avatar for NathanOliver
0
105
Member Avatar for Mitnick06

**can u help me how to convert a pdf to docx file extension using a php or javascript?**

Member Avatar for SautinSoft
0
180
Member Avatar for de Source

hi i have an string array in which i have combinations of 0's and 1's like on index 0 i have "01", on index 1 i have "11", on index 2 i have "00", on index 3 i have"10" etc is their any possibilty that i can take these values …

Member Avatar for ddanbe
0
211
Member Avatar for Hazuan Nazri

hello, i need some help here, i already bind my database coloumn 'NAMA' to my combobox 'cbNAMA', and now i want to show data from my database on textbox by selecting the row using cbNAMA but i got this error "System.InvalidCastExeception: Conversion from type 'DBNULL' to type 'String' is not …

Member Avatar for G_Waddell
0
1K
Member Avatar for DangleSauce19

My code works for numbers that dont have a remainder of 10 or above, but whenever I get one with a remainder 10 or above it prints out the number, not the letter. Please help #include <iostream> #include <fstream> using namespace std; const int maxstack = 51; class stack_type { …

Member Avatar for WaltP
0
2K
Member Avatar for somjit{}

i was watching [this video](http://www.youtube.com/watch?v=jTSvthW34GU&list=EC9D558D49CA734A02&index=2&feature=plpp_video) about type conversion and what the compiler does while converting from small byte formats to large byte formats(and vice versa) etc etc, and tried to write a code for it... but seems that function calls in my code are getting completely bypassed... once again, here …

Member Avatar for somjit{}
0
401

The End.