Search Results

Search found 85 results on 4 pages for 'ivar'.

Page 1/4 | 1 2 3 4  | Next Page >

  • Objective C: Which is changed, property or ivar?

    - by Wilhelmsen
    Worrying about duplicates but can not seem to find and answer I can understand in any of the other posts, I just have to ask: When I have in my .h: @interface SecondViewController : UIViewController{ NSString *changeName; } @property (readwrite, retain) NSString *changeName; then in my .m @synthesize changeName; -(IBAction)changeButton:(id)sender{ changeName = @"changed"; } Is it the synthesized property or the instance variable that get changed when I press "changeButton" ?

    Read the article

  • ivar is inside two blocks

    - by Desperate Developer
    I have an ivar like this declared on interface: BOOL controllerOK; I have to use this ivar inside a block that resides itself in a block. Something like myBlockl = ^(){ [self presentViewController:controller animated:YES completion:^(){ if (controllerOK) [self doStuff]; }]; }; If I try to do that, I see an error capturing self strongly in this block is likely to lead to a retain cycle for the if (controllerOK) line. This does not appear to be one of those blocks problems that you create another variable using __unsafe_unretained before the block starts. First because this instruction cannot be used with a BOOL and second because the ivar controllerOK has to be tested on runtime inside the block. Another problem is that the block itself is declared on the interface, so it will be used outside the context where it is being created. How do I solve that?

    Read the article

  • Synthesized property of a protocol not seeing superclass' ivar

    - by hyn
    I have a situation where my subclass is not seeing the superclass' instance variable x. The ivar is obviously @protected by default, so why do I get a compiler error "x undeclared"? - (CGSize)hitSize { // Compiler error return size; } EDIT: hitSize is a property of a protocol my subclass is conforming to. The problem was that I had hitSize @synthesized, which was the culprit. The question then is why can't the synthesized getter see the ivar?

    Read the article

  • Ivar definitions show 'long' type encoding as 'long long' type encoding

    - by Frank C.
    I've found what I think may be a bug with Ivar and Objective-C runtime. I'm using XCode 3.2.1 and associated libraries, developing a 64 bit app on X86_64 (MacBook Pro). Where I would expect the type encoding for the following "longVal" to be 'l', the Ivar encoding is showing a 'q' (which is a 'long long'). Anyone else seeing this? Simplified code and output follows: Code: #import <Foundation/Foundation.h> #import <objc/runtime.h> @interface Bug : NSObject { long longVal; long long longerVal; } @property (nonatomic,assign) long longVal; @property (nonatomic,assign) long long longerVal; @end @implementation Bug @synthesize longVal,longerVal; @end int main (int argc, const char * argv[]) { NSAutoreleasePool * pool = [[NSAutoreleasePool alloc] init]; unsigned int ivarCount=0; Ivar *ivars= class_copyIvarList([Bug class], &ivarCount); for(unsigned int x=0;x<ivarCount;x++) { NSLog(@"Name [%@] encoding [%@]", [NSString stringWithCString:ivar_getName(ivars[x]) encoding:NSUTF8StringEncoding], [NSString stringWithCString:ivar_getTypeEncoding(ivars[x]) encoding:NSUTF8StringEncoding]); } [pool drain]; return 0; } And here is output from debug console: This GDB was configured as "x86_64-apple-darwin".tty /dev/ttys000 Loading program into debugger… sharedlibrary apply-load-rules all Program loaded. run [Switching to process 6048] Running… 2010-03-17 22:16:29.138 ivarbug[6048:a0f] Name [longVal] encoding [q] 2010-03-17 22:16:29.146 ivarbug[6048:a0f] Name [longerVal] encoding [q] (gdb) continue Not a pretty picture! -- Frank

    Read the article

  • Does different iVar name change retain count when used with property

    - by russell
    Here is 2 code snapshot- Class A:NSObject { NSMutableArray *a; } @property (retain) NSMutableArray *a; @implementation @synthesize a; -(id)init { if(self=[super init]) { a=[[NSMutableArray alloc] init]; } } @end Class A:NSObject { NSMutableArray *_a; } @property (retain) NSMutableArray *a; @implementation @synthesize a=_a; -(id)init { if(self=[super init]) { _a=[[NSMutableArray alloc] init]; } } @end Now what i need to know, is in both code instance variable assigned value directly rather than using accessor and retain count is 1? Or there is difference between them. Thanks. And one more things, apple recommended not to use accessor in init/dealloc, but at the same time ask not to directly set iVar. So what is the best way to assign value of ivar in init()??

    Read the article

  • NSTimer as a self-targeting ivar.

    - by Matt Wilding
    I have come across an awkward situation where I would like to have a class with an NSTimer instance variable that repeatedly calls a method of the class as long as the class is alive. For illustration purposes, it might look like this: // .h @interface MyClock : NSObject { NSTimer* _myTimer; } - (void)timerTick; @end - // .m @implementation MyClock - (id)init { self = [super init]; if (self) { _myTimer = [[NSTimer scheduledTimerWithTimeInterval:1.0f target:self selector:@selector(timerTick) userInfo:nil repeats:NO] retain]; } return self; } - (void)dealloc { [_myTimer invalidate]; [_myTImer release]; [super dealloc]; } - (void)timerTick { // Do something fantastic. } @end That's what I want. I don't want to to have to expose an interface on my class to start and stop the internal timer, I just want it to run while the class exists. Seems simple enough. But the problem is that NSTimer retains its target. That means that as long as that timer is active, it is keeping the class from being dealloc'd by normal memory management methods because the timer has retained it. Manually adjusting the retain count is out of the question. This behavior of NSTimer seems like it would make it difficult to ever have a repeating timer as an ivar, because I can't think of a time when an ivar should retain its owning class. This leaves me with the unpleasant duty of coming up with some method of providing an interface on MyClock that allows users of the class to control when the timer is started and stopped. Besides adding unneeded complexity, this is annoying because having one owner of an instance of the class invalidate the timer could step on the toes of another owner who is counting on it to keep running. I could implement my own pseudo-retain-count-system for keeping the timer running but, ...seriously? This is way to much work for such a simple concept. Any solution I can think of feels hacky. I ended up writing a wrapper for NSTimer that behaves exactly like a normal NSTimer, but doesn't retain its target. I don't like it, and I would appreciate any insight.

    Read the article

  • Setting ivar in objective-c from child view in the iPhone

    - by Ivan
    Hi there! Maybe a FAQ at this website. I have a TableViewController that holds a form. In that form I have two fields (each in it's own cell): one to select who paid (single selection), and another to select people expense is paid for (multiple selection). Both fields open a new TableViewController included in an UINavigationController. Single select field (Paid By) holds an object Membership Multiple select field (Paid For) holds an object NSMutableArray Both vars are being sent to the new controller identically the same way: mySingleSelectController.crSelectedMember = self.crPaidByMember; myMultipleSelectController.crSelectedMembers = self.crSelectedMembers; From Paid for controller I use didSelectAtIndexPath method to set a mutable array of Memberships for whom is paid: if ([[tableView cellForRowAtIndexPath:indexPath] accessoryType] == UITableViewCellAccessoryCheckmark) { [self.crSelectedMembers removeObject:[self.crGroupMembers objectAtIndex:indexPath.row]]; //... } else { [self.crSelectedMembers addObject:[self.crGroupMembers objectAtIndex:indexPath.row]]; //... } So far everything goes well. An mutable array (crSelectedMembers) is perfectly set from child view. But... I have trouble setting Membership object. From Paid By controller I use didSelectAtIndexPath to set Membership: [self setCrSelectedMember:[crGroupMembers objectAtIndex:indexPath.row]]; By NSlogging crSelectedMember I get the right selected member in self, but in parent view, to which ivar is pointed, nothing is changed. Am I doing something wrong? Cause I CAN call the method of crSelectedMembers, but I can't change the value of crSelectedMember.

    Read the article

  • Inheritance issue with ivar on the iPhone

    - by Buffalo
    I am using the BLIP/MYNetwork library to establish a basic tcp socket connection between the iPhone and my computer. So far, the code builds and runs correctly in simulator but deploying to device yields the following error: error: property 'delegate' attempting to use ivar '_delegate' declared in super class of 'TCPConnection' @interface TCPConnection : TCPEndpoint { @private TCPListener *_server; IPAddress *_address; BOOL _isIncoming, _checkedPeerCert; TCPConnectionStatus _status; TCPReader *_reader; TCPWriter *_writer; NSError *_error; NSTimeInterval _openTimeout; } /** The delegate object that will be called when the connection opens, closes or receives messages. */ @property (assign) id<TCPConnectionDelegate> delegate; /** The delegate messages sent by TCPConnection. All methods are optional. */ @protocol TCPConnectionDelegate <NSObject> @optional /** Called after the connection successfully opens. */ - (void) connectionDidOpen: (TCPConnection*)connection; /** Called after the connection fails to open due to an error. */ - (void) connection: (TCPConnection*)connection failedToOpen: (NSError*)error; /** Called when the identity of the peer is known, if using an SSL connection and the SSL settings say to check the peer's certificate. This happens, if at all, after the -connectionDidOpen: call. */ - (BOOL) connection: (TCPConnection*)connection authorizeSSLPeer: (SecCertificateRef)peerCert; /** Called after the connection closes. You can check the connection's error property to see if it was normal or abnormal. */ - (void) connectionDidClose: (TCPConnection*)connection; @end @interface TCPEndpoint : NSObject { NSMutableDictionary *_sslProperties; id _delegate; } - (void) tellDelegate: (SEL)selector withObject: (id)param; @end Does anyone know how I would fix this? Would I simply declare _delegate as a public property of the base class "TCPEndPoint"? Thanks for the help ya'll!

    Read the article

  • iOS: Assignment to iVar in Block (ARC)

    - by manmal
    I have a readonly property isFinished in my interface file: typedef void (^MyFinishedBlock)(BOOL success, NSError *e); @interface TMSyncBase : NSObject { BOOL isFinished_; } @property (nonatomic, readonly) BOOL isFinished; and I want to set it to YES in a block at some point later, without creating a retain cycle to self: - (void)doSomethingWithFinishedBlock:(MyFinishedBlock)theFinishedBlock { __weak MyClass *weakSelf = self; MyFinishedBlock finishedBlockWrapper = ^(BOOL success, NSError *e) { [weakSelf willChangeValueForKey:@"isFinished"]; weakSelf -> isFinished_ = YES; [weakSelf didChangeValueForKey:@"isFinished"]; theFinishedBlock(success, e); }; self.finishedBlock = finishedBlockWrapper; // finishedBlock is a class ext. property } I'm unsure that this is the right way to do it (I hope I'm not embarrassing myself here ^^). Will this code leak, or break, or is it fine? Perhaps there is an easier way I have overlooked? SOLUTION Thanks to the answers below (especially Krzysztof Zablocki), I was shown the way to go here: Define isFinished as readwrite property in the class extension (somehow I missed that one) so no direct ivar assignment is needed, and change code to: - (void)doSomethingWithFinishedBlock:(MyFinishedBlock)theFinishedBlock { __weak MyClass *weakSelf = self; MyFinishedBlock finishedBlockWrapper = ^(BOOL success, NSError *e) { MyClass *strongSelf = weakSelf; strongSelf.isFinished = YES; theFinishedBlock(success, e); }; self.finishedBlock = finishedBlockWrapper; // finishedBlock is a class ext. property }

    Read the article

  • TableView - iVar reset when returning from details view

    - by iFloh
    Hi, anyone knows what I need to do to retain my TableView iVars whilst pushing a details view onto the navigation stack? I have an array and a date defined as iVars and the array is retained, whilst the date is not. I checked whether there may be an autorelease hidden somewhere but there are no obvious ones. The properties are defined as nonatomic, retain. I use custom NSDate category methods to determine specific dates at stages. These use NSDateComponents, NSRange and NSCalendar, for example: - (NSDate *)lastDayOfMonth: { NSCalendar *tmpCal = [NSCalendar currentCalendar]; NSDateComponents *tmpDateComponents = [tmpCal components:NSYearCalendarUnit | NSMonthCalendarUnit | NSEraCalendarUnit | NSWeekCalendarUnit | NSWeekdayOrdinalCalendarUnit fromDate:self]; NSRange tmpRange = [tmpCal rangeOfUnit:NSDayCalendarUnit inUnit:NSMonthCalendarUnit forDate:[tmpCal dateFromComponents:tmpDateComponents]]; [tmpDateComponents setDay:tmpRange.length]; [tmpDateComponents setHour:23]; [tmpDateComponents setMinute:59]; [tmpDateComponents setSecond:59]; return [[NSCalendar currentCalendar] dateFromComponents:tmpDateComponents]; } could they somehow be the reason?

    Read the article

  • Proper NSArray initialization for ivar data in a method

    - by Joost Schuur
    I'm new to Objective-C and iPhone development and have been using Apress' Beginning iPhone 3 Programming book as my main guide for a few weeks now. In a few cases as part of a viewDidLoad: method, ivars like a breadTypes NSArray are initialized like below, with an intermediate array defined and then ultimately set to the actual array like this: NSArray *breadArray = [[NSArray alloc] initWithObjects:@"White", @"Whole Weat", @"Rye", @"Sourdough", @"Seven Grain", nil]; self.breadTypes = breadArray; [breadArray release]; Why is it done this way, instead of simply like this: self.breadTypes = [[NSArray alloc] initWithObjects:@"White", @"Whole Weat", @"Rye", @"Sourdough", @"Seven Grain", nil]; Both seem to work when I compile and run it. Is the 2nd method above not doing proper memory management? I assume initWithObjects: returns an array with a retain count of 1 and I eventually release breadTypes again in the dealloc: method, so that wraps things up nicely. I'm guessing 'self.breadTypes = ...' copies the data to the new array, which is why the original array can be safely released, correct?

    Read the article

  • Setting default values for inherited property without using accessor in Objective-C?

    - by Ben Stock
    I always see people debating whether or not to use a property's setter in the -init method. I don't know enough about the Objective-C language yet to have an opinion one way or the other. With that said, lately I've been sticking to ivars exclusively. It seems cleaner in a way. I don't know. I digress. Anyway, here's my problem … Say we have a class called Dude with an interface that looks like this: @interface Dude : NSObject { @private NSUInteger _numberOfGirlfriends; } @property (nonatomic, assign) NSUInteger numberOfGirlfriends; @end And an implementation that looks like this: @implementation Dude - (instancetype)init { self = [super init]; if (self) { _numberOfGirlfriends = 0; } } @end Now let's say I want to extend Dude. My subclass will be called Playa. And since a playa should have mad girlfriends, when Playa gets initialized, I don't want him to start with 0; I want him to have 10. Here's Playa.m: @implementation Playa - (instancetype)init { self = [super init]; if (self) { // Attempting to set the ivar directly will result in the compiler saying, // "Instance variable `_numberOfGirlfriends` is private." // _numberOfGirlfriends = 10; <- Can't do this. // Thus, the only way to set it is with the mutator: self.numberOfGirlfriends = 10; // Or: [self setNumberOfGirlfriends:10]; } } @end So what's a Objective-C newcomer to do? Well, I mean, there's only one thing I can do, and that's set the property. Unless there's something I'm missing. Any ideas, suggestions, tips, or tricks? Sidenote: The other thing that bugs me about setting the ivar directly — and what a lot of ivar-proponents say is a "plus" — is that there are no KVC notifications. A lot of times, I want the KVC magic to happen. 50% of my setters end in [self setNeedsDisplay:YES], so without the notification, my UI doesn't update unless I remember to manually add -setNeedsDisplay. That's a bad example, but the point stands. I utilize KVC all over the place, so without notifications, things can act wonky. Anyway, any info is much appreciated. Thanks!

    Read the article

  • Why call autorelease for iVar definition in init method?

    - by iFloh
    Hi, I just familiarise myself with the CLLocationManager and found several sample class definitions that contain the following init method: - (id) init { self = [super init]; if (self != nil) { self.locationManager = [[[CLLocationManager alloc] init] autorelease]; self.locationManager.delegate = self; } return self; } - (void)dealloc { [self.locationManager release]; [super dealloc]; } I don't understand why the iVar would be autoreleased. Does this not mean it is deallocated at the end of the init method? I am also puzzled to see the same sample codes have the iVar release in the dealloc method. Any thoughts? '

    Read the article

  • Argument passing regarding ivars

    - by StoneBreaker
    I am passing an iVar into a function. The iVar is a double. The value of the iVar inside the function is correct, but the value of the iVar outside the function is not changed. This must have something to do with the way that I am receiving the iVar into the function. How do I pass a double iVar in so that its value is changed in the object and not only in the function? I do the same thing with pointers and the results are as expected, so I think I am not understanding scalar argument passing in c/objective-c.

    Read the article

  • Converting 'x' value of a CGPoint ivar to NSTimeInterval?

    - by eco_bach
    Hi I have a velocity ivar defined as a CGPoint. I need to somehow extract just the 'x' value of velocity, and then use this to call-send a message to the following method signature -(void) adjustTimer:(NSTimeInterval*)newInterval How do I obtain just the 'x' value of a CGPoint? Do I then need to convert or cast this result before calling my adjustTimer method?

    Read the article

  • objective c- property

    - by Amir
    Hello all , I think i am missing somthing with property attributes. first i cant understand the different between retain and assign? If i use assign does the property increase the retain counter by 1 to the setter and also to the getter, and i need to use release to both of them? and how this work with readwrite or copy? from the view of retain count. I am trying to understand when i need to use release after working with property(setter and getter) @property (readwrite,assign) int iVar; what does assing do here?? what is the different between : @property (readwrite,assign) int iVar; to @property (readwrite,retain) int iVar; to @property (readwrite) int iVar; many thanks...

    Read the article

  • nonatomic property in model class when using NSOperationQueue (iPhone)?

    - by Andrew B.
    I have a custom model class with an NSMutableData ivar that will be accessed by custom NSOperation subclasses (using an NSOperationQueue). I think I can guarantee thread-safe access to the ivar from multiple NSOperations by using dependencies, and I can guarantee that I don't access the ivar from other code (say my main app thread) by waiting until the Q has finished all operations. Should I use a nonatomic property specification, or leave it atomic? Is there a significant impact on performance?

    Read the article

  • How should developers handle subpar working conditions? [closed]

    - by ivar
    I have been working in my current job for less than a year and at the beginning didn't have the courage to say anything about the things that bothered me. Now I'm a bit fed up and need things to get better. The first problem is not random but I'll mention it anyway. We are running out of space so every new employee gets a smaller table. We are promised that the space problem will be fixed soon. Almost every employee has a different keyboard, mouse, headphones (if any). Mine are $10 keyboard, some random cheap mouse and some random crappy headphones with a mic. All these were used and dirty when I got them. The number of monitor is 1-3 and with different sizes. I have 2 nice monitors and can't complain but some are given 1 small monitor. When it's their first job they don't have the guts to ask for 2 even if most others have 2. Nobody seems to care too. Project manager asked if it's ok? He obviously said he can handle the 1 small one. Then the manager said you can go ask for 1 more. I'm watching this and think go and ask where? The company is trying to hire more people but is not doing much after the person has signed the contract. We are put in one room that is open to the hallway and it's super noisy. Almost like a zoo at times. Even if nobody is talking the crappy keyboards make too much noise. Is this normal? Am I too negative and should I just do my job with what I was given? Should I demand better things? Should the company have some system that everybody gets things in some price range?

    Read the article

  • Ongoing confusion about ivars and properties in objective C

    - by Earl Grey
    After almost 8 months being in ios programming, I am again confused about the right approach. Maybe it is not the language but some OOP principle I am confused about. I don't know.. I was trying C# a few years back. There were fields (private variables, private data in an object), there were getters and setters (methods which exposed something to the world) ,and properties which was THE exposed thing. I liked the elegance of the solution, for example there could be a class that would have a property called DailyRevenue...a float...but there was no private variable called dailyRevenue, there was only a field - an array of single transaction revenues...and the getter for DailyRevenue property calculated the revenue transparently. If somehow the internals of daily revenue calculation would change, it would not affect somebody who consumed my DailyRevenue property in any way, since he would be shielded from getter implementation. I understood that sometimes there was , and sometimes there wasn't a 1-1 relationship between fields and properties. depending on the requirements. It seemed ok in my opinion. And that properties are THE way to acces the data in object. I know the difference betweeen private, protected, and public keyword. Now lets get to objectiveC. On what factor should I base my decision about making someting only an ivar or making it as a property? Is the mental model the same as I describe above? I know that ivars are "protected" by default, not "private" asi in c#..But thats ok I think, no big deal for my presnet level of understanding the whole ios development. The point is ivars are not accesible from outside (given i don't make them public..but i won't). The thing that clouds my clear understanding is that I can have IBOutlets from ivars. Why am I seeing internal object data in the UI? *Why is it ok?* On the other hand, if I make an IBOutlet from property, and I do not make it readonly, anybody can change it. Is this ok too? Let's say I have a ParseManager object. This object would use a built in Foundation framework class called NSXMLParser. Obviously my ParseManager will utilize this nsxmlparser's capabilities but will also do some additional work. Now my question is, who should initialize this NSXMLParser object and in which way should I make a reference to it from the ParseManager object, when there is a need to parse something. A) the ParseManager -1) in its default init method (possible here ivar - or - ivar+ppty) -2) with lazyloading in getter (required a ppty here) B) Some other object - who will pass a reference to NSXMLParser object to the ParseManager object. -1) in some custom initializer (initWithParser:(NSXMLPArser *) parser) when creating the ParseManager object.. A1 - the problem is, we create a parser and waste memory while it is not yet needed. However, we can be sure that all methods that are part ot ParserManager object, can use the ivar safely, since it exists. A2 - the problem is, the nsxmlparser is exposed to outside world, although it could be read only. Would we want a parser to be exposed in some scenario? B1 - this could maybe be useful when we would want to use more types of parsers..i dont know... I understand that architectural requirements and and language is not the same. But clearly the two are in relation. How to get out of that mess of my? Please bear with me, I wasn't able to come up with a single ultimate question. And secondly, it's better to not scare me with some superadvanced newspeak that talks about some crazy internals (what the compiler does) and edge cases.

    Read the article

  • (Not So) Silly Objective-C inheritance problem when using property - GCC Bug?

    - by Ben Packard
    Update 2 - Many people are insisting I need to declare an iVar for the property. Some are saying not so, as I am using Modern Runtime (64 bit). I can confirm that I have been successfully using @property without iVars for months now. Therefore, I think the 'correct' answer is an explanation as to why on 64bit I suddenly have to explicitly declare the iVar when (and only when) i'm going to access it from a child class. The only one I've seen so far is a possible GCC bug (thanks Yuji). Not so simple after all... Update - I messed up one line of the original copy and paste - corrected. The @property call was missing (nonatomic, retain) but is a red herring - STILL NEED AN ANSWER! Thanks. I've been scratching my head with this for a couple of hours - I haven't used inheritance much. Here I have set up a simple Test B class that inherits from Test A, where an ivar is declared. But I get the compilation error that the variable is undeclared. This only happens when I add the property and synthesize declarations - works fine without them. TestA Header: #import <Cocoa/Cocoa.h> @interface TestA : NSObject { NSString *testString; } @end TestA Implementation is empty: #import "TestA.h" @implementation TestA @end TestB Header: #import <Cocoa/Cocoa.h> #import "TestA.h" @interface TestB : TestA { } @property (nonatomic, retain) NSString *testProp; @end TestB Implementation (Error - 'testString' is undeclared) #import "TestB.h" @implementation TestB @synthesize testProp; - (void)testing{ NSLog(@"test ivar is %@", testString); } @end

    Read the article

  • NSDate & Memory management

    - by iFloh
    Hi, memory management still gives me grief. This time it is an NSDate iVar that I init using NSDate *myNSDate = [[NSDate date] firstDayOfMonth]; with a method call to - (NSDate *)firstDayOfMonth { NSDateComponents *tmpDateComponents = [[NSCalendar currentCalendar] components:NSYearCalendarUnit | NSMonthCalendarUnit | NSEraCalendarUnit | NSWeekCalendarUnit | NSWeekdayOrdinalCalendarUnit fromDate:self]; [tmpDateComponents setDay:1]; [tmpDateComponents setHour:0]; [tmpDateComponents setMinute:0]; [tmpDateComponents setSecond:0]; return [[NSCalendar currentCalendar] dateFromComponents:tmpDateComponents]; } At the end of the init call the retain count is at 1 (Note the iVar is not defined as a property). When I step into the viewWillAppear method the myNSDate has vanished. I tried to do an explicit retain on it, but that only lasts until I update the iVar using the above method again. I though - ok - I add the retain to the return of the function, but that makes the leak analyser throw up an error. What am I doing wrong?

    Read the article

  • Should you correct compiler warnings about type conversions using explicit typecasts?

    - by BastiBechtold
    In my current project, the compiler shows hundreds of warnings about type conversions. There is a lot of code like this iVar = fVar1*fVar2/fVar3; // or even iVar = fVar1*fVar2/fVar3+.5f; which intentionally assign float values to int. Of course, I could fix these warnings using iVar = int(...); but that looks kind of ugly. Would you rather live with the ugliness or live with the warnings? Or is there even a clean solution?

    Read the article

  • How to copy mailboxes from Exchange 2003 to Exchange 2007 across forests?

    - by Tor Ivar Larsen
    Hi. Were going through a quite difficult conversion from an old ASP-solution to an entirely new one. This includes moving mailboxes from Ex2003 to Ex2007. We want to do this without deleting the old mailboxes on the Ex2003 server, to have a "fall back" in case somehing goes wrong. I have investigated the "Move-Mailbox" cmdlet in the Ex2007 shell, and it seems to fit our needs quite well. The only problem being that we want to keep the old mailboxes. This could easily be accomplished with the -SourceMailboxCleanupOptions, but we can't use this when we have used the -AllowMerge switch. The reason we need -AllowMerge is because all the user accounts with connected mailboxes are already created on Ex2007(Some automatic user creation tool, no real relevance to the case in question) The twist is that the exchange servers are in two different forests... Windows 2003 SP1 on DC1, Windows 2003 SP2 on DC2 in forest 1. Windows 2003 R2 SP2 on DC1 in forest 2. Can we use the Move-Mailbox safely for this purpose? And if yes, how?

    Read the article

1 2 3 4  | Next Page >