473,396 Members | 2,158 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

System.Math.DivRem for compact framework

Howdy all,

what is the same DivRem function for Mobile development. I'm using the
..NET compact framework.

Thanks all,

Marcelo Muzilli

May 31 '06 #1
4 4158

mu*****@sercomtel.com.br wrote:
Howdy all,

what is the same DivRem function for Mobile development. I'm using the
.NET compact framework.

Thanks all,

Marcelo Muzilli


If it's not supported by the CF, then you will have to use a
combination of Integer division and Mod to obtain the same result.

May 31 '06 #2
Thanks Chris for the quick response.
If it's not supported by the CF, then you will have to use a
combination of Integer division and Mod to obtain the same result.


In my line:

System.Math.DivRem(this.BlockCounter, 2, out Result);

Can you help me with the solution?

Thanks,

MM

May 31 '06 #3
Is this correct?

double Result;
// System.Math.DivRem(this.BlockCounter, 2, out Result);
Result = (this.BlockCounter % 2);

Many thanks,

MM

May 31 '06 #4

mu*****@sercomtel.com.br wrote:
Is this correct?

double Result;
// System.Math.DivRem(this.BlockCounter, 2, out Result);
Result = (this.BlockCounter % 2);

Many thanks,

MM


The mod operator (%) will give you the remainder, but for the quotient
portion of it you would have to also do a divide operation. You have
to do both to emulate the behavior of the DivRem method since that
method returns both a quotient and a remainder.

Jun 1 '06 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: boble | last post by:
Sorry, it's may be off topic ;_((( The following article http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnppc2k3/ht ml/winmob03.asp states that a.. Microsoft Windows .NET...
2
by: Duncan | last post by:
I am using the evaluation version of CE.NET 4.1. I had also installed the release version of the Compact Framework. I uninstalled the CE.NET 4.1, and then realized I needed it again and...
1
by: Asad Khan | last post by:
Hi, I have Visual Studio 2002 Enterprise Architecture Edition. I was wondering if anyone has any information on how I can develop applications for .Net Compact Framework using this IDE. I've heard...
4
by: Sehri | last post by:
Hi all, I have just started developing a math companion tool with VS2005 and I just ran into a problem when trying to add the description of a formula. Doed anyone know how can I add math...
0
by: BuddyWork | last post by:
Hello, Here is an update. There is no differences with the function System.Math.Log10 under any operating system. The problem is with the casting of the datatype double and value Infinite...
5
by: bob | last post by:
Hi Using 2003 - targeting the compact framework (c#), but would like to do most development using the full.net (manually leaving out stuff not in the compact framework). Q. Trying to find a...
8
by: Tim Reynolds | last post by:
Our .Net application calls a web method of aplpication 2 that resides on their Apache server. When I as a developer C#, Studios 2003, make the call to their web method from my desktop, I receive no...
8
by: Gonza | last post by:
Hi group, i have a method in my class with the following code: private double GetCompletedPercentage(TimeSpan totalTime, TimeSpan budgetedTime) { double totalMinutes = totalTime.TotalMinutes;...
2
by: George | last post by:
Hello everyone, I have used Visual Studio 2005 to create a C# .Net Compact Framework 1.0 application on Pocket Pc 2003 device. But when building the application, there are some errors dealing...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.